aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-i386/paravirt.h
diff options
context:
space:
mode:
authorZachary Amsden <zach@vmware.com>2007-04-08 19:04:01 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-04-08 22:47:55 -0400
commit49f19710512c825aaea73b9207b3a848027cda1d (patch)
tree06da31bd9a84273e12aa43f536f90eb8146ff92e /include/asm-i386/paravirt.h
parenta5bfffac645a7b2d8119f8bbae34df5c94832799 (diff)
[PATCH] Proper fix for highmem kmap_atomic functions for VMI for 2.6.21
Since lazy MMU batching mode still allows interrupts to enter, it is possible for interrupt handlers to try to use kmap_atomic, which fails when lazy mode is active, since the PTE update to highmem will be delayed. The best workaround is to issue an explicit flush in kmap_atomic_functions case; this is the only way nested PTE updates can happen in the interrupt handler. Thanks to Jeremy Fitzhardinge for noting the bug and suggestions on a fix. This patch gets reverted again when we start 2.6.22 and the bug gets fixed differently. Signed-off-by: Zachary Amsden <zach@vmware.com> Cc: Andi Kleen <ak@muc.de> Cc: Jeremy Fitzhardinge <jeremy@goop.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/asm-i386/paravirt.h')
-rw-r--r--include/asm-i386/paravirt.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/asm-i386/paravirt.h b/include/asm-i386/paravirt.h
index 46dc34ca887a..e63f1e444fcf 100644
--- a/include/asm-i386/paravirt.h
+++ b/include/asm-i386/paravirt.h
@@ -421,14 +421,17 @@ static inline void pmd_clear(pmd_t *pmdp)
421#define PARAVIRT_LAZY_NONE 0 421#define PARAVIRT_LAZY_NONE 0
422#define PARAVIRT_LAZY_MMU 1 422#define PARAVIRT_LAZY_MMU 1
423#define PARAVIRT_LAZY_CPU 2 423#define PARAVIRT_LAZY_CPU 2
424#define PARAVIRT_LAZY_FLUSH 3
424 425
425#define __HAVE_ARCH_ENTER_LAZY_CPU_MODE 426#define __HAVE_ARCH_ENTER_LAZY_CPU_MODE
426#define arch_enter_lazy_cpu_mode() paravirt_ops.set_lazy_mode(PARAVIRT_LAZY_CPU) 427#define arch_enter_lazy_cpu_mode() paravirt_ops.set_lazy_mode(PARAVIRT_LAZY_CPU)
427#define arch_leave_lazy_cpu_mode() paravirt_ops.set_lazy_mode(PARAVIRT_LAZY_NONE) 428#define arch_leave_lazy_cpu_mode() paravirt_ops.set_lazy_mode(PARAVIRT_LAZY_NONE)
429#define arch_flush_lazy_cpu_mode() paravirt_ops.set_lazy_mode(PARAVIRT_LAZY_FLUSH)
428 430
429#define __HAVE_ARCH_ENTER_LAZY_MMU_MODE 431#define __HAVE_ARCH_ENTER_LAZY_MMU_MODE
430#define arch_enter_lazy_mmu_mode() paravirt_ops.set_lazy_mode(PARAVIRT_LAZY_MMU) 432#define arch_enter_lazy_mmu_mode() paravirt_ops.set_lazy_mode(PARAVIRT_LAZY_MMU)
431#define arch_leave_lazy_mmu_mode() paravirt_ops.set_lazy_mode(PARAVIRT_LAZY_NONE) 433#define arch_leave_lazy_mmu_mode() paravirt_ops.set_lazy_mode(PARAVIRT_LAZY_NONE)
434#define arch_flush_lazy_mmu_mode() paravirt_ops.set_lazy_mode(PARAVIRT_LAZY_FLUSH)
432 435
433/* These all sit in the .parainstructions section to tell us what to patch. */ 436/* These all sit in the .parainstructions section to tell us what to patch. */
434struct paravirt_patch { 437struct paravirt_patch {