Skip to contentSkip to conversation

Patch "perf bench numa: Fix to show proper convergence stats" has been added to the 4.1-stable tree

PATCH [email protected] 1 participant 1 message Jul 31, 2015

Subsystems (2)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

perf bench numa: Fix to show proper convergence stats

to the 4.1-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
perf-bench-numa-fix-to-show-proper-convergence-stats.patch
and it can be found in the queue-4.1 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From 2b42b09b88c831ba4da2d669581dde371c38c2af Mon Sep 17 00:00:00 2001

From: Srikar Dronamraju <[email protected]>
Date: Wed, 24 Jun 2015 16:40:04 +0530
Subject: perf bench numa: Fix to show proper convergence stats

From: Srikar Dronamraju <[email protected]>

commit 2b42b09b88c831ba4da2d669581dde371c38c2af upstream.

With commit: e1e455f4f4d3 (perf tools: Work around lack of sched_getcpu in glibc < 2.6), perf_bench numa mem with -c or -m option is not able to correctly calculate convergence.

With the above commit, sched_getcpu always seems to return -1. The intention of commit e1e455f was to add a sched_getcpu in glibc < 2.6. Hence keep the sched_getcpu definition under an ifdef.

This regression happened occurred between v4.0 and v4.1

Cc Jiri Olsa <[email protected]>
Cc Masami Hiramatsu <[email protected]>
Cc Namhyung Kim <[email protected]>
Cc Vinson Lee <[email protected]>
Fixes e1e455f4f4d3 ("perf tools: Work around lack of sched_getcpu in glibc < 2.6")
---
 tools/perf/util/cloexec.c |    4 ++++
 1 file changed, 4 insertions(+)
tools/perf/util/cloexec.c +4 -0
@@ -7,11 +7,15 @@
 
 static unsigned long flag = PERF_FLAG_FD_CLOEXEC;
 
+#ifdef __GLIBC_PREREQ
+#if !__GLIBC_PREREQ(2, 6)
 int __weak sched_getcpu(void)
 {
 	errno = ENOSYS;
 	return -1;
 }
+#endif
+#endif
 
 static int perf_flag_probe(void)
 {

Patches currently in stable-queue which might be from [email protected] are

queue-4.1/perf-bench-numa-fix-to-show-proper-convergence-stats.patch