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:	Mon, 14 Jan 2008 21:12:14 +0100
From:	Sam Ravnborg <sam@...nborg.org>
To:	Ingo Molnar <mingo@...e.hu>
Cc:	Adrian Bunk <bunk@...nel.org>, Andi Kleen <andi@...stfloor.org>,
	rjw@...k.pl, pavel@...e.cz, linux-kernel@...r.kernel.org
Subject: Re: [PATCH x86] [15/16] Force __cpuinit on for CONFIG_PM without HOTPLUG_CPU

On Mon, Jan 14, 2008 at 04:24:40PM +0100, Ingo Molnar wrote:
> 
> * Ingo Molnar <mingo@...e.hu> wrote:
> 
> > also, in theory we've got a pretty reliable set of the following 
> > information:
> > 
> >   function X references symbol Y
> > 
> > and we know what type of sections they are in, right?
> > 
> > could -ffunction-sections be used to delay the categorization of 
> > functions to the link stage, and in essence remove the need to mark 
> > functions via any of the __init markers?
> 
> find below the current set of warnings on -git. There are 62.

The correct figure is 112.

You need to do a:
make KCFLAGS=-fno-unit-at-a-time
build to see them all.

> 
> for example, instead of the rather cryptic:
> 
>   WARNING: vmlinux.o(.text+0x1815e): Section mismatch: reference to 
>   .init.text:calibrate_delay (between 'smp_callin' and '__cpu_up')
> 
> the following output would be more informative:
> 
> --------------------------------->
> | function:
> |
> |  ./init/calibrate.c:void __devinit calibrate_delay(void)
> |
> | calls:
> |
> |  ./arch/x86/kernel/smpboot_32.c:static void __cpuinit smp_callin(void)
> |
> | but calibrate_delay() is __devinit while smp_callin() is __cpuinit. 
> | Change smp_callin() to __devinit to resolve this warning.
> |-------------------------------->
> 
> would result in a lot faster cycles of fixing this.
> 
> do we have all the info to print this?

Not yet. The patch I posted on lkml bring us one step further.
At modpost time today we only see .init.text and .text but
with the suggested patch we will be able to see what section
a function belong to and we are several steps closer to better
error messages.

So let me get that into shape and I will revisit the messages.

In this case I would not know if calibrate_delay() should be
__cpuinit or smp_callin() should be __devinit looking at the
information modpost has available without additional digging.
But a quick grep tells me that the right fix is to annotate
calibrate_delay() with __cpuinit because is is used from
either __cpuinit annotated or __init annotated functions.

	Sam

--
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