summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorXuheng Li <xuheng@cs.columbia.edu>2026-11-09 22:13:35 +0000
committerMarc Zyngier <maz@kernel.org>2026-11-11 09:37:35 +0000
commitfe5946524be82b1eeb1da17949684afc56087ff7 (patch)
treee4e1f77b79032850226ce51166d1d23dcc8aee96 /tools/perf/scripts/python
parentd41bb3229ce8f573fd1f9d56e946604cb14324b0 (diff)
KVM: arm64: Don't replace a valid hyp block mapping with a table
When kvm_pgtable_hyp_map() is asked to map part of a range that a valid block mapping already covers, hyp_map_walker_try_leaf() declines, as the request cannot be a leaf at the block's level. hyp_map_walker() then allocates a zeroed table and stores it over the valid block entry. The walk descends into the new table and maps the requested pages, but the rest of the block is now unmapped, and the valid block was replaced without break-before-make. No in-tree caller maps into an existing hyp block mapping today, so this cannot be triggered in mainline. Fail such a request with -EEXIST instead, so that a future caller gets an error rather than silently losing the rest of the block. The same check now catches a conflicting remap of an existing leaf, so drop the WARN_ON() from hyp_map_walker_try_leaf(): every caller checks the error, and a WARN is fatal at EL2. Do the check before the last-level WARN_ON(), which is kept for internal errors, and update the kernel-doc of kvm_pgtable_hyp_map() to match. Signed-off-by: Xuheng Li <xuheng@cs.columbia.edu> Reviewed-by: Vincent Donnefort <vdonnefort@google.com> Link: https://patch.msgid.link/20261109-hyp-block-map-v3-1-bd70e67eb0bf@cs.columbia.edu Signed-off-by: Marc Zyngier <maz@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions