diff options
author | Peter Zijlstra <peterz@infradead.org> | 2020-10-30 12:15:06 +0100 |
---|---|---|
committer | Peter Zijlstra <peterz@infradead.org> | 2020-11-09 18:12:35 +0100 |
commit | e506d1dac0edb2df82f2aa0582e814f9cd9aa07d (patch) | |
tree | 73b80f8166e06db89e768ca9e99729e8ec1d1139 /arch | |
parent | perf/arch: Remove perf_sample_data::regs_user_copy (diff) | |
download | linux-e506d1dac0edb2df82f2aa0582e814f9cd9aa07d.tar.xz linux-e506d1dac0edb2df82f2aa0582e814f9cd9aa07d.zip |
perf/x86: Make dummy_iregs static
Having pt_regs on-stack is unfortunate, it's 168 bytes. Since it isn't
actually used, make it a static variable. This both gets if off the
stack and ensures it gets 0 initialized, just in case someone does
look at it.
Reported-by: Steven Rostedt <rostedt@goodmis.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20201030151955.324273677@infradead.org
Diffstat (limited to 'arch')
-rw-r--r-- | arch/x86/events/intel/ds.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/events/intel/ds.c b/arch/x86/events/intel/ds.c index 276b29da732f..b47cc4226934 100644 --- a/arch/x86/events/intel/ds.c +++ b/arch/x86/events/intel/ds.c @@ -1738,7 +1738,7 @@ __intel_pmu_pebs_event(struct perf_event *event, struct x86_perf_regs perf_regs; struct pt_regs *regs = &perf_regs.regs; void *at = get_next_pebs_record_by_bit(base, top, bit); - struct pt_regs dummy_iregs; + static struct pt_regs dummy_iregs; if (hwc->flags & PERF_X86_EVENT_AUTO_RELOAD) { /* |