summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2021-06-24 17:55:12 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2021-06-24 17:55:12 +0200
commitdf5011000496355d8508d56cd3ce45b1196b8b43 (patch)
treee8b469c9425664a69775ff1eff2a011747e38013 /arch
parentMerge tag 'objtool-urgent-2021-06-24' of git://git.kernel.org/pub/scm/linux/k... (diff)
parentperf/x86/intel/lbr: Zero the xstate buffer on allocation (diff)
downloadlinux-df5011000496355d8508d56cd3ce45b1196b8b43.tar.xz
linux-df5011000496355d8508d56cd3ce45b1196b8b43.zip
Merge tag 'perf-urgent-2021-06-24' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull x86 perf fix from Ingo Molnar: "An LBR buffer fix for code that probably only worked accidentally" * tag 'perf-urgent-2021-06-24' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: perf/x86/intel/lbr: Zero the xstate buffer on allocation
Diffstat (limited to 'arch')
-rw-r--r--arch/x86/events/intel/lbr.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/x86/events/intel/lbr.c b/arch/x86/events/intel/lbr.c
index 4409d2cccfda..e8453de7a964 100644
--- a/arch/x86/events/intel/lbr.c
+++ b/arch/x86/events/intel/lbr.c
@@ -731,7 +731,8 @@ void reserve_lbr_buffers(void)
if (!kmem_cache || cpuc->lbr_xsave)
continue;
- cpuc->lbr_xsave = kmem_cache_alloc_node(kmem_cache, GFP_KERNEL,
+ cpuc->lbr_xsave = kmem_cache_alloc_node(kmem_cache,
+ GFP_KERNEL | __GFP_ZERO,
cpu_to_node(cpu));
}
}