lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sat,  6 Jun 2009 16:37:23 +0200
From:	Frederic Weisbecker <fweisbec@...il.com>
To:	Ingo Molnar <mingo@...e.hu>
Cc:	LKML <linux-kernel@...r.kernel.org>,
	Frederic Weisbecker <fweisbec@...il.com>,
	Steven Rostedt <rostedt@...dmis.org>,
	Andrew Morton <akpm@...ux-foundation.org>
Subject: [PATCH] tracing/branch-tracer: PROFILE_BRANCHES_PER_CPU must depend on SMP

Ingo,

Please pull this fixlet, made against tip:tracing/branch-tracer.
It fixes a build failure you've reported recently.

Thanks.

The following changes since commit e482f8395f215e0ad6557b2722cd9b9b308035c4:
  Steven Rostedt (1):
        tracing/branch-profiler: add option to profile branches per cpu

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/frederic/random-tracing.git tracing/branch-tracer

Frederic Weisbecker (1):
      tracing/branch-tracer: PROFILE_BRANCHES_PER_CPU must depend on SMP

 kernel/trace/Kconfig |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

---

>From cb0473e6be6f68fbf7ddc95c9c3ff7610b8598ca Mon Sep 17 00:00:00 2001
From: Frederic Weisbecker <fweisbec@...il.com>
Date: Sat, 6 Jun 2009 16:24:33 +0200
Subject: [PATCH] tracing/branch-tracer: PROFILE_BRANCHES_PER_CPU must depend on SMP
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit

While enabling the per cpu branch tracing in a non SMP config,
we get the following build failure:

kernel/trace/trace_branch.c: In function ‘branch_profiler’:
kernel/trace/trace_branch.c:353: error: implicit declaration of function ‘SHIFT_PERCPU_PTR’
kernel/trace/trace_branch.c:353: error: implicit declaration of function ‘per_cpu_offset’
kernel/trace/trace_branch.c:353: error: invalid type argument of ‘->’ (have ‘int’)
kernel/trace/trace_branch.c: In function ‘calculate_stat’:
kernel/trace/trace_branch.c:364: error: invalid type argument of ‘unary *’ (have ‘int’)
kernel/trace/trace_branch.c:366: error: invalid type argument of ‘->’ (have ‘int’)
kernel/trace/trace_branch.c:367: error: invalid type argument of ‘->’ (have ‘int’)

This is because the branch tracer uses per cpu internals that are not
supported on !CONFIG_SMP case.

To fix it we just need to disable the per cpu branch tracing in
!CONFIG_SMP case.

[ Impact: fix a build failure with the branch tracer ]

Reported-by: Ingo Molnar <mingo@...e.hu>
Cc: Steven Rostedt <rostedt@...dmis.org>
Signed-off-by: Frederic Weisbecker <fweisbec@...il.com>
---
 kernel/trace/Kconfig |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/kernel/trace/Kconfig b/kernel/trace/Kconfig
index 309a264..0efbcc5 100644
--- a/kernel/trace/Kconfig
+++ b/kernel/trace/Kconfig
@@ -285,7 +285,7 @@ endchoice
 
 config PROFILE_BRANCHES_PER_CPU
 	bool "Profile branches on a per cpu basis"
-	depends on PROFILE_ALL_BRANCHES
+	depends on PROFILE_ALL_BRANCHES && SMP
 	help
 	  When profiling all branches, the system can take a big cache line
 	  bouncing hit. On boxes with lots of CPUs, this can slow the system
-- 
1.6.2.3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ