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-next>] [day] [month] [year] [list]
Date:	Sat, 21 Mar 2009 12:41:39 +0100
From:	Heiko Carstens <heiko.carstens@...ibm.com>
To:	Ingo Molnar <mingo@...e.hu>, Steven Rostedt <rostedt@...dmis.org>,
	Sam Ravnborg <sam@...nborg.org>
Cc:	<linux-kernel@...r.kernel.org>
Subject: [PATCH] trace/ring_buffer: fix section mismatch warning

From: Heiko Carstens <heiko.carstens@...ibm.com>

With linux-next I get this:

Section mismatch in reference from the function ring_buffer_alloc() to the function .cpuinit.text:rb_cpu_notify()
The function ring_buffer_alloc() references
the function __cpuinit rb_cpu_notify().
This is often because ring_buffer_alloc lacks a __cpuinit 
annotation or the annotation of rb_cpu_notify is wrong.

This is a false positive since rb_cpu_notify gets only referenced if
CONFIG_HOTPLUG_CPU=y.
To get rid of the warning annotate ring_buffer_alloc with __ref.

Signed-off-by: Heiko Carstens <heiko.carstens@...ibm.com>
---
 kernel/trace/ring_buffer.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: linux-next/kernel/trace/ring_buffer.c
===================================================================
--- linux-next.orig/kernel/trace/ring_buffer.c
+++ linux-next/kernel/trace/ring_buffer.c
@@ -549,7 +549,7 @@ static int __cpuinit rb_cpu_notify(struc
  * when the buffer wraps. If this flag is not set, the buffer will
  * drop data when the tail hits the head.
  */
-struct ring_buffer *ring_buffer_alloc(unsigned long size, unsigned flags)
+struct ring_buffer * __ref ring_buffer_alloc(unsigned long size, unsigned flags)
 {
 	struct ring_buffer *buffer;
 	int bsize;
--
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