mirror of
https://github.com/torvalds/linux.git
synced 2026-05-30 18:13:41 +02:00
riscv: define ILLEGAL_POINTER_VALUE for 64bit
This is used in poison.h for poison pointer offset. Based on current
SV39, SV48 and SV57 vm layout, 0xdead000000000000 is a proper value
that is not mappable, this can avoid potentially turning an oops to
an expolit.
Signed-off-by: Jisheng Zhang <jszhang@kernel.org>
Fixes: fbe934d69e ("RISC-V: Build Infrastructure")
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/20240705170210.3236-1-jszhang@kernel.org
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
This commit is contained in:
parent
d6a1928134
commit
5c178472af
|
|
@ -320,6 +320,11 @@ config GENERIC_HWEIGHT
|
||||||
config FIX_EARLYCON_MEM
|
config FIX_EARLYCON_MEM
|
||||||
def_bool MMU
|
def_bool MMU
|
||||||
|
|
||||||
|
config ILLEGAL_POINTER_VALUE
|
||||||
|
hex
|
||||||
|
default 0 if 32BIT
|
||||||
|
default 0xdead000000000000 if 64BIT
|
||||||
|
|
||||||
config PGTABLE_LEVELS
|
config PGTABLE_LEVELS
|
||||||
int
|
int
|
||||||
default 5 if 64BIT
|
default 5 if 64BIT
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user