Remove unnecessary TLB flushes
- this should be only for SMP
This commit is contained in:
parent
df9928711b
commit
2d1c8849d8
2 changed files with 3 additions and 1 deletions
|
@ -803,7 +803,7 @@ ENTRY(__switch_address_space)
|
||||||
* test if the cr3 is loaded with the current value to avoid unnecessary
|
* test if the cr3 is loaded with the current value to avoid unnecessary
|
||||||
* TLB flushes
|
* TLB flushes
|
||||||
*/
|
*/
|
||||||
#if 0
|
#ifndef CONFIG_SMP
|
||||||
mov %cr3, %ecx
|
mov %cr3, %ecx
|
||||||
cmp %ecx, %eax
|
cmp %ecx, %eax
|
||||||
je 0f
|
je 0f
|
||||||
|
|
|
@ -374,7 +374,9 @@ check_misc_flags:
|
||||||
p->p_misc_flags &= ~MF_CONTEXT_SET;
|
p->p_misc_flags &= ~MF_CONTEXT_SET;
|
||||||
|
|
||||||
assert(!(p->p_misc_flags & MF_FULLVM) || p->p_seg.p_cr3 != 0);
|
assert(!(p->p_misc_flags & MF_FULLVM) || p->p_seg.p_cr3 != 0);
|
||||||
|
#ifdef CONFIG_SMP
|
||||||
refresh_tlb();
|
refresh_tlb();
|
||||||
|
#endif
|
||||||
/*
|
/*
|
||||||
* restore_user_context() carries out the actual mode switch from kernel
|
* restore_user_context() carries out the actual mode switch from kernel
|
||||||
* to userspace. This function does not return
|
* to userspace. This function does not return
|
||||||
|
|
Loading…
Reference in a new issue