diff options
author | Rusty Russell <rusty@rustcorp.com.au> | 2013-04-22 00:40:40 -0400 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2013-04-22 02:15:01 -0400 |
commit | 3412b6ae2924e068f9932f841bdea0f2d8424502 (patch) | |
tree | 75b499710ee82715c864d5787383ad35a9cd47bd /drivers/lguest/core.c | |
parent | f1f394b1c33d93416c90f97e201d4d386c04af55 (diff) |
lguest: don't share Switcher PTE pages between guests.
We currently use the whole top PGD entry for the switcher, so we
simply share a fixed page of PTEs between all guests (actually, it's
one per Host CPU, to ensure isolation between guests).
Changes to a scheme where every guest has its own mappings.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'drivers/lguest/core.c')
-rw-r--r-- | drivers/lguest/core.c | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/drivers/lguest/core.c b/drivers/lguest/core.c index b6c71c32308c..7e1d7ee36478 100644 --- a/drivers/lguest/core.c +++ b/drivers/lguest/core.c | |||
@@ -333,15 +333,10 @@ static int __init init(void) | |||
333 | if (err) | 333 | if (err) |
334 | goto out; | 334 | goto out; |
335 | 335 | ||
336 | /* Now we set up the pagetable implementation for the Guests. */ | ||
337 | err = init_pagetables(lg_switcher_pages); | ||
338 | if (err) | ||
339 | goto unmap; | ||
340 | |||
341 | /* We might need to reserve an interrupt vector. */ | 336 | /* We might need to reserve an interrupt vector. */ |
342 | err = init_interrupts(); | 337 | err = init_interrupts(); |
343 | if (err) | 338 | if (err) |
344 | goto free_pgtables; | 339 | goto unmap; |
345 | 340 | ||
346 | /* /dev/lguest needs to be registered. */ | 341 | /* /dev/lguest needs to be registered. */ |
347 | err = lguest_device_init(); | 342 | err = lguest_device_init(); |
@@ -356,8 +351,6 @@ static int __init init(void) | |||
356 | 351 | ||
357 | free_interrupts: | 352 | free_interrupts: |
358 | free_interrupts(); | 353 | free_interrupts(); |
359 | free_pgtables: | ||
360 | free_pagetables(); | ||
361 | unmap: | 354 | unmap: |
362 | unmap_switcher(); | 355 | unmap_switcher(); |
363 | out: | 356 | out: |
@@ -369,7 +362,6 @@ static void __exit fini(void) | |||
369 | { | 362 | { |
370 | lguest_device_remove(); | 363 | lguest_device_remove(); |
371 | free_interrupts(); | 364 | free_interrupts(); |
372 | free_pagetables(); | ||
373 | unmap_switcher(); | 365 | unmap_switcher(); |
374 | 366 | ||
375 | lguest_arch_host_fini(); | 367 | lguest_arch_host_fini(); |