diff options
author | Rusty Russell <rusty@rustcorp.com.au> | 2013-04-22 06:40:38 +0200 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2013-04-22 08:01:36 +0200 |
commit | 93a2cdff98243df06bafd3c4f3b31b38f0d0fe3e (patch) | |
tree | cfda9a918a92ac0308e1c888489c83c0b243138a /drivers/lguest/x86 | |
parent | lguest: rename switcher_page to switcher_pages. (diff) | |
download | linux-93a2cdff98243df06bafd3c4f3b31b38f0d0fe3e.tar.xz linux-93a2cdff98243df06bafd3c4f3b31b38f0d0fe3e.zip |
lguest: assume Switcher text is a single page.
ie. SHARED_SWITCHER_PAGES == 1. It is well under a page, and it's a
minor simplification: it's nice to have *one* simplification in a
patch series!
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'drivers/lguest/x86')
-rw-r--r-- | drivers/lguest/x86/core.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/lguest/x86/core.c b/drivers/lguest/x86/core.c index 20fae765d600..f0a3347b6441 100644 --- a/drivers/lguest/x86/core.c +++ b/drivers/lguest/x86/core.c @@ -62,11 +62,10 @@ static unsigned long switcher_offset(void) return switcher_addr - (unsigned long)start_switcher_text; } -/* This cpu's struct lguest_pages. */ +/* This cpu's struct lguest_pages (after the Switcher text page) */ static struct lguest_pages *lguest_pages(unsigned int cpu) { - return &(((struct lguest_pages *) - (switcher_addr + SHARED_SWITCHER_PAGES*PAGE_SIZE))[cpu]); + return &(((struct lguest_pages *)(switcher_addr + PAGE_SIZE))[cpu]); } static DEFINE_PER_CPU(struct lg_cpu *, lg_last_cpu); |