aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/gdb/linux/utils.py
diff options
context:
space:
mode:
authorAndy Lutomirski <luto@kernel.org>2025-04-02 11:45:35 +0200
committerIngo Molnar <mingo@kernel.org>2025-04-12 10:05:46 +0200
commit81e3cbdef230fd9adfa8569044b07290afd66708 (patch)
tree218cc34bd5a174c4920f89a105d269bf8b090189 /scripts/gdb/linux/utils.py
parentx86/mm: Add 'mm' argument to unuse_temporary_mm() (diff)
downloadlinux-rng-81e3cbdef230fd9adfa8569044b07290afd66708.tar.xz
linux-rng-81e3cbdef230fd9adfa8569044b07290afd66708.zip
x86/events, x86/insn-eval: Remove incorrect current->active_mm references
When decoding an instruction or handling a perf event that references an LDT segment, if we don't have a valid user context, trying to access the LDT by any means other than SLDT is racy. Certainly, using current->active_mm is wrong, as active_mm can point to a real user mm when CR3 and LDTR no longer reference that mm. Clean up the code. If nmi_uaccess_okay() says we don't have a valid context, just fail. Otherwise use current->mm. Signed-off-by: Andy Lutomirski <luto@kernel.org> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Signed-off-by: Ingo Molnar <mingo@kernel.org> Cc: Rik van Riel <riel@surriel.com> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Link: https://lore.kernel.org/r/20250402094540.3586683-3-mingo@kernel.org
Diffstat (limited to 'scripts/gdb/linux/utils.py')
0 files changed, 0 insertions, 0 deletions