]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/64e: Move virtual memory closer to linear memory
authorChristophe Leroy <christophe.leroy@csgroup.eu>
Tue, 28 Jun 2022 14:48:57 +0000 (16:48 +0200)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 29 Jun 2022 07:04:15 +0000 (17:04 +1000)
commit8f33f5e7afc03c51798aa5bcb300f46dd6cfc908
tree8a322cc1de4c04fb8c3c39e438a30b3ef01b9db4
parent45d7ac6fd46baddf336366bd75bea2b0dfac31f4
powerpc/64e: Move virtual memory closer to linear memory

Today nohash/64 have linear memory based at 0xc000000000000000 and
virtual memory based at 0x8000000000000000.

In order to implement KASAN, we need to regroup both areas.

Move virtual memmory at 0xc000100000000000.

This complicates a bit TLB miss handlers. Until now, memory region
was easily identified with the 4 higher bits of address:
- 0 ==> User
- c ==> Linear Memory
- 8 ==> Virtual Memory

Now we need to rely on the 20 higher bits, with:
- 0xxxx ==> User
- c0000 ==> Linear Memory
- c0001 ==> Virtual Memory

Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/4b225168031449fc34fc7132f3923cc8dc54af60.1656427701.git.christophe.leroy@csgroup.eu
arch/powerpc/include/asm/nohash/64/pgtable.h
arch/powerpc/mm/nohash/tlb_low_64e.S