summaryrefslogtreecommitdiff
path: root/i386/intel/pmap.c
diff options
context:
space:
mode:
Diffstat (limited to 'i386/intel/pmap.c')
-rw-r--r--i386/intel/pmap.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/i386/intel/pmap.c b/i386/intel/pmap.c
index 697e5f8..02482ae 100644
--- a/i386/intel/pmap.c
+++ b/i386/intel/pmap.c
@@ -332,7 +332,13 @@ lock_data_t pmap_system_lock;
#define MAX_TBIS_SIZE 32 /* > this -> TBIA */ /* XXX */
#define INVALIDATE_TLB(s, e) { \
- flush_tlb(); \
+ if (((e) - (s)) > 32 * PAGE_SIZE) { \
+ flush_tlb(); \
+ } else { \
+ vm_offset_t i; \
+ for (i = s; i < e; i += PAGE_SIZE) \
+ invlpg(i); \
+ } \
}