lkml.org 
[lkml]   [2008]   [Jan]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 0/7] More lguest massage.
Date
inour model, a guest does not run in a cpu anymore: a virtual cpu
does.So we change last_guest to last_cpu

Signed-off-by:Glauber de Oliveira Costa <gcosta@redhat.com>
---
drivers/lguest/x86/core.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)

diff--git a/drivers/lguest/x86/core.c b/drivers/lguest/x86/core.c
index2859447..25f48fd 100644
---a/drivers/lguest/x86/core.c
+++b/drivers/lguest/x86/core.c
@@-60,7 +60,7 @@ static struct lguest_pages *lguest_pages(unsigned int cpu)
(SWITCHER_ADDR + SHARED_SWITCHER_PAGES*PAGE_SIZE))[cpu]);
}

-staticDEFINE_PER_CPU(struct lguest *, last_guest);
+staticDEFINE_PER_CPU(struct lg_cpu *, last_cpu);

/*S:010
* We approach the Switcher.
@@-80,8 +80,8 @@ static void copy_in_guest_info(struct lg_cpu *cpu, struct lguest_pages *pages)
* same Guest we ran last time (and that Guest hasn't run anywhere else
* meanwhile). If that's not the case, we pretend everything in the
* Guest has changed. */
- if(__get_cpu_var(last_guest) != lg || lg->last_pages != pages) {
- __get_cpu_var(last_guest)= lg;
+ if(__get_cpu_var(last_cpu) != cpu || lg->last_pages != pages) {
+ __get_cpu_var(last_cpu)= cpu;
lg->last_pages = pages;
lg->changed = CHANGED_ALL;
}
--
1.5.0.6



\
 
 \ /
  Last update: 2008-01-18 01:39    [W:0.317 / U:0.044 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site