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]
Message-ID: <20090723050522.GA8887@merkur.ravnborg.org>
Date:	Thu, 23 Jul 2009 07:05:22 +0200
From:	Sam Ravnborg <sam@...nborg.org>
To:	Matthias Klose <doko@...ntu.com>,
	binutils <binutils@...rceware.org>,
	Bastian Blank <waldi@...ian.org>,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	linux-kernel@...r.kernel.org, Kiko Piris <kernel@...ispons.net>,
	Damien Wyart <damien.wyart@...e.fr>, Greg KH <gregkh@...e.de>,
	Wolfgang Walter <wolfgang.walter@...m.de>
Subject: Re: current binutils trunk fails to build bootable kernel image
	for some configurations

On Thu, Jul 23, 2009 at 10:19:39AM +0930, Alan Modra wrote:
> On Wed, Jul 22, 2009 at 01:04:57PM -0400, Matthias Klose wrote:
> > this was reported as http://bugs.debian.org/537389, I currently don't 
> > have much more information, besides that one of the Debian kernel 
> > maintainers did identify
> >
> > 2009-07-11  Alan Modra  <amodra@...pond.net.au>
> >
> >         * ldlang.c (insert_os_after): Don't tie assignments to non-alloc
> >         output sections.
> >
> > this patch as the one causing the wrongly built kernel. However I don't 
> > see this checkin mentioned on the ML.
> 
> The discussion happened on bug-binutils.
> http://lists.gnu.org/archive/html/bug-binutils/2009-07/msg00067.html
> 
> > Bastian Blank did check that the 
> > problem goes away with a binutils build from trunk and this patch 
> > reverted. Some more analysis in http://lkml.org/lkml/2009/7/21/400
> 
> The biggest problem is that the kernel linker script doesn't mention
> all sections, which means ld must choose a place for the unmentioned
> sections (orphans).  Sometimes ld's placement isn't how a naive
> programmer would expect.
> 
> In this case:
> 
>   . = ALIGN(PAGE_SIZE);
>   .data_nosave : AT(ADDR(.data_nosave) - LOAD_OFFSET) {
> 
> ld stuck an orphan section between the two statements.  Which meant
> that the start of .data_nosave is not aligned (and since the end is
> aligned by following statements, it means that .data_nosave also has
> padding inserted).  It would be more robust to write:
> 
>   .data_nosave ALIGN(PAGE_SIZE) : AT(ADDR(.data_nosave) - LOAD_OFFSET) {

Do you recall when this started to be supported?
I think I tried this and it failed - but I may be wrong here.

Also - do there exist an option to tell what sections has not been
covered by a linker script?

	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