- patches.fixes/patch-2.6.11-rc1: 2.6.11-rc1.
[linux-flexiantxendom0-3.2.10.git] / include / asm-x86_64 / mmu_context.h
index 8f80f15..673126c 100644 (file)
@@ -40,10 +40,7 @@ static inline void switch_mm(struct mm_struct *prev, struct mm_struct *next,
                write_pda(active_mm, next);
 #endif
                set_bit(cpu, &next->cpu_vm_mask);
-               /* Re-load page tables */
-               *read_pda(level4_pgt) = __pa(next->pgd) | _PAGE_TABLE;
-               __flush_tlb();
-
+               asm volatile("movq %0,%%cr3" :: "r" (__pa(next->pgd)) : "memory");
                if (unlikely(next->context.ldt != prev->context.ldt)) 
                        load_LDT_nolock(&next->context, cpu);
        }