Commit 4afb0be7 authored by Joakim Tjernlund's avatar Joakim Tjernlund Committed by Benjamin Herrenschmidt

powerpc/8xx: Avoid testing for kernel space in ITLB Miss.

Only modules will cause ITLB Misses as we always pin
the first 8MB of kernel memory.
Signed-off-by: default avatarJoakim Tjernlund <Joakim.Tjernlund@transmode.se>
Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
parent fe1691e3
...@@ -318,12 +318,16 @@ InstructionTLBMiss: ...@@ -318,12 +318,16 @@ InstructionTLBMiss:
/* If we are faulting a kernel address, we have to use the /* If we are faulting a kernel address, we have to use the
* kernel page tables. * kernel page tables.
*/ */
#ifdef CONFIG_MODULES
/* Only modules will cause ITLB Misses as we always
* pin the first 8MB of kernel memory */
andi. r11, r10, 0x0800 /* Address >= 0x80000000 */ andi. r11, r10, 0x0800 /* Address >= 0x80000000 */
beq 3f beq 3f
lis r11, swapper_pg_dir@h lis r11, swapper_pg_dir@h
ori r11, r11, swapper_pg_dir@l ori r11, r11, swapper_pg_dir@l
rlwimi r10, r11, 0, 2, 19 rlwimi r10, r11, 0, 2, 19
3: 3:
#endif
lwz r11, 0(r10) /* Get the level 1 entry */ lwz r11, 0(r10) /* Get the level 1 entry */
rlwinm. r10, r11,0,0,19 /* Extract page descriptor page address */ rlwinm. r10, r11,0,0,19 /* Extract page descriptor page address */
beq 2f /* If zero, don't try to find a pte */ beq 2f /* If zero, don't try to find a pte */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment