diff options
author | Peter Zijlstra <[email protected]> | 2022-10-27 14:54:41 -0700 |
---|---|---|
committer | Dave Hansen <[email protected]> | 2022-12-15 10:37:26 -0800 |
commit | 97e3d26b5e5f371b3ee223d94dd123e6c442ba80 (patch) | |
tree | 80ee0994078b5307c6edd071d36574313c995243 /tools/perf/scripts/python/stackcollapse.py | |
parent | 3f148f3318140035e87decc1214795ff0755757b (diff) |
x86/mm: Randomize per-cpu entry area
Seth found that the CPU-entry-area; the piece of per-cpu data that is
mapped into the userspace page-tables for kPTI is not subject to any
randomization -- irrespective of kASLR settings.
On x86_64 a whole P4D (512 GB) of virtual address space is reserved for
this structure, which is plenty large enough to randomize things a
little.
As such, use a straight forward randomization scheme that avoids
duplicates to spread the existing CPUs over the available space.
[ bp: Fix le build. ]
Reported-by: Seth Jenkins <[email protected]>
Reviewed-by: Kees Cook <[email protected]>
Signed-off-by: Peter Zijlstra (Intel) <[email protected]>
Signed-off-by: Dave Hansen <[email protected]>
Signed-off-by: Borislav Petkov <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions