]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/8xx: Always fault when _PAGE_ACCESSED is not set
authorChristophe Leroy <christophe.leroy@csgroup.eu>
Mon, 12 Oct 2020 08:54:31 +0000 (08:54 +0000)
committerMichael Ellerman <mpe@ellerman.id.au>
Thu, 5 Nov 2020 12:34:25 +0000 (23:34 +1100)
commitdf32348be101e5c9437adda888c94ce1a1368523
treeafa516e084a724fcb6ebf2f5d93232661dbec35f
parent90c6ef8da2a5def5e2b27b7d0938baa6cd9f3e7c
powerpc/8xx: Always fault when _PAGE_ACCESSED is not set

The kernel expects pte_young() to work regardless of CONFIG_SWAP.

Make sure a minor fault is taken to set _PAGE_ACCESSED when it
is not already set, regardless of the selection of CONFIG_SWAP.

This adds at least 3 instructions to the TLB miss exception
handlers fast path. Following patch will reduce this overhead.

Also update the rotation instruction to the correct number of bits
to reflect all changes done to _PAGE_ACCESSED over time.

Fixes: 2742ea2b5129 ("powerpc/8xx: Don't touch ACCESSED when no SWAP.")
Fixes: 9d7d67b469d1 ("powerpc/8xx: remove unused _PAGE_WRITETHRU")
Fixes: ff5afe5a0ea7 ("powerpc/8xx: Handle PAGE_USER via APG bits")
Fixes: 68fe13eb6576 ("powerpc/8xx: Implementation of PAGE_EXEC")
Fixes: 42466e31a947 ("powerpc/8xx: Prepare handlers for _PAGE_HUGE for 512k pages.")
Cc: stable@vger.kernel.org
Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/af834e8a0f1fa97bfae65664950f0984a70c4750.1602492856.git.christophe.leroy@csgroup.eu
arch/powerpc/kernel/head_8xx.S