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] [day] [month] [year] [list]
Message-ID: <20080412165645.GA6717@uranus.ravnborg.org>
Date:	Sat, 12 Apr 2008 18:56:45 +0200
From:	Sam Ravnborg <sam@...nborg.org>
To:	Jacek Luczak <difrost.kernel@...il.com>
Cc:	Ingo Molnar <mingo@...e.hu>, LKML <linux-kernel@...r.kernel.org>,
	tglx@...utronix.de
Subject: Re: [PATCH] x86: setup_trampoline() - fix section mismatch warning

On Sat, Apr 12, 2008 at 01:00:32PM +0200, Jacek Luczak wrote:
> 
> Hi Sam,
> 
> Sam Ravnborg pisze:
> [!snip]
> >> diff --git a/arch/x86/kernel/trampoline_64.S b/arch/x86/kernel/trampoline_64.S
> >> index 4aedd0b..2a07e67 100644
> >> --- a/arch/x86/kernel/trampoline_64.S
> >> +++ b/arch/x86/kernel/trampoline_64.S
> >> @@ -32,7 +32,7 @@
> >>  
> >>  /* We can free up trampoline after bootup if cpu hotplug is not supported. */
> >>  #ifndef CONFIG_HOTPLUG_CPU
> >> -.section .init.data, "aw", @progbits
> >> +.section .cpuinit.data, "aw", @progbits
> >>  #else
> >>  .section .rodata, "a", @progbits
> >>  #endif
> > 
> > The correct fix would be to drop the
> > preprocessor directves and use __CPUINITDATA
> 
> Hmm...IMO this should stay in that form at least now.
> I will make some tests with __CPUINITDATA (look into objects, etc.) and later on we can
> switch. Is it OK for you?

I should maybe give you a little more background.
The __cpuinitdata section is properly discarded after init
has completed in case CPUHOTPLUG is not needed.
But in case it is needed then the section is kept.

So the only issue with introducing the patch as I suggest
is that we loose the readonly. We need to introduce
__CPUINITCONST to cover that case.
But loosing readonly is not a big deal here.

If you insist on the readonly part then unconditionally
use the section named .cpuinit.rodata
But the preprocessor directive should in any case be dropped
as it is of no real use today.

	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