diff options
| author | Kan Liang <[email protected]> | 2025-03-14 17:26:58 +0000 |
|---|---|---|
| committer | Peter Zijlstra <[email protected]> | 2025-03-17 10:23:37 +0000 |
| commit | 3cec9fd03543c1e2919f906353e5cba079ae0a7c (patch) | |
| tree | 36b4ffa0b33a49fa8b401bbe1927748a1ce48211 /net/unix/af_unix.c | |
| parent | perf: Supply task information to sched_task() (diff) | |
| download | kernel-3cec9fd03543c1e2919f906353e5cba079ae0a7c.tar.gz kernel-3cec9fd03543c1e2919f906353e5cba079ae0a7c.zip | |
perf/x86/lbr: Fix shorter LBRs call stacks for the system-wide mode
In the system-wide mode, LBR callstacks are shorter in comparison to
the per-process mode.
LBR MSRs are reset during a context switch in the system-wide mode. For
the LBR call stack, the LBRs should be always saved/restored during a
context switch.
Use the space in task_struct to save/restore the LBR call stack data.
For a system-wide event, it's unnecessagy to update the
lbr_callstack_users for each threads. Add a variable in x86_pmu to
indicate whether the system-wide event is active.
Fixes: 76cb2c617f12 ("perf/x86/intel: Save/restore LBR stack during context switch")
Reported-by: Andi Kleen <[email protected]>
Reported-by: Alexey Budankov <[email protected]>
Debugged-by: Alexey Budankov <[email protected]>
Signed-off-by: Kan Liang <[email protected]>
Signed-off-by: Peter Zijlstra (Intel) <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'net/unix/af_unix.c')
0 files changed, 0 insertions, 0 deletions
