summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/task-analyzer.py
diff options
context:
space:
mode:
authorKarl Mehltretter <kmehltretter@gmail.com>2026-07-29 02:42:54 +0200
committerWill Deacon <will@kernel.org>2026-08-02 09:46:07 +0000
commitc3f83d021162571bcd87b062ec9e587828d2b7f3 (patch)
tree4ab335ab7eb5f4a15b0c278323df60e24b74883f /tools/perf/scripts/python/task-analyzer.py
parenta13c140cc289c0b7b3770bce5b3ad42ab35074aa (diff)
arm64/fpsimd: ptrace: Fix inactive SVE and SSVE regsets
sve_init_header_from_task() takes header as a pointer, so for the inactive mode header->size = sizeof(header); stores 8 rather than sizeof(struct user_sve_header), which is 16. Userspace sees an impossible size smaller than the header it describes. The inactive-mode check in sve_get_common() compares header.size against sizeof(header) as well, but there header is a struct, so the check can never fire. Reads of NT_ARM_SVE and NT_ARM_SSVE for the inactive mode therefore still return the other mode's FPSIMD data, exactly the situation the check was added to prevent. Fix the size, and make the check return the remaining membuf space instead of 0, which regset_get() would interpret as the entire (zero-filled) buffer having been populated. Fixes: b93e685ecff7 ("arm64/fpsimd: ptrace: Do not present register data for inactive mode") Assisted-by: Claude:claude-opus-5 Signed-off-by: Karl Mehltretter <kmehltretter@gmail.com> Signed-off-by: Will Deacon <will@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/task-analyzer.py')
0 files changed, 0 insertions, 0 deletions