RE: [PATCH] powerpc: link error on orphan sections

2016-10-19 Thread David Laight
From: Michael Ellerman [mailto:m...@ellerman.id.au] > > In the past I've caused orphan sections to error by assigning them > > to the same address as something that exists. > > Works with all linkers, even if the error message isn't as useful. > > How do you assign them an address without knowing

RE: [PATCH] powerpc: link error on orphan sections

2016-10-19 Thread Michael Ellerman
David Laight writes: > From: Michael Ellerman >> Sent: 14 October 2016 01:46 > ... >> > +LDFLAGS_vmlinux := $(LDFLAGS_vmlinux-y) --orphan-handling=error >> >> At least some old(er) toolchains don't support that: >> >> /opt/cross/kisskb/gcc-4.6.3-nolibc/powerpc-linux/bin/powerpc-linux-ld: >

RE: [PATCH] powerpc: link error on orphan sections

2016-10-14 Thread David Laight
From: Michael Ellerman > Sent: 14 October 2016 01:46 ... > > +LDFLAGS_vmlinux:= $(LDFLAGS_vmlinux-y) --orphan-handling=error > > At least some old(er) toolchains don't support that: > > /opt/cross/kisskb/gcc-4.6.3-nolibc/powerpc-linux/bin/powerpc-linux-ld: > unrecognized option '-- > orpha

Re: [PATCH] powerpc: link error on orphan sections

2016-10-13 Thread Nicholas Piggin
On Fri, 14 Oct 2016 13:35:54 +1100 Balbir Singh wrote: > On 12/10/16 18:00, Nicholas Piggin wrote: > > Add --orphan-handling=error to final link flags. This ensures we have to > > handle all sections. This would have caught subtle breakage such as > > 7de3b27bac47da9de08409df1d69664acbb72197 at b

Re: [PATCH] powerpc: link error on orphan sections

2016-10-13 Thread Nicholas Piggin
the same sections from other files. How's this? Might take a few iterations to smooth out all toolchains From: Nicholas Piggin Date: Thu, 22 Sep 2016 18:41:14 +1000 Subject: [PATCH] powerpc: link error on orphan sections Add --orphan-handling=error to final link flags. This ensures we have

Re: [PATCH] powerpc: link error on orphan sections

2016-10-13 Thread Michael Ellerman
Nicholas Piggin writes: > diff --git a/arch/powerpc/kernel/vmlinux.lds.S > b/arch/powerpc/kernel/vmlinux.lds.S > index 8295f51..9f4d85e 100644 > --- a/arch/powerpc/kernel/vmlinux.lds.S > +++ b/arch/powerpc/kernel/vmlinux.lds.S > @@ -317,6 +319,16 @@ SECTIONS > _end = . ; > PROVIDE32

Re: [PATCH] powerpc: link error on orphan sections

2016-10-13 Thread Balbir Singh
On 12/10/16 18:00, Nicholas Piggin wrote: > Add --orphan-handling=error to final link flags. This ensures we have to > handle all sections. This would have caught subtle breakage such as > 7de3b27bac47da9de08409df1d69664acbb72197 at build-time. > > Also bring some wayward sections into the fold:

Re: [PATCH] powerpc: link error on orphan sections

2016-10-13 Thread Michael Ellerman
Nicholas Piggin writes: > Add --orphan-handling=error to final link flags. This ensures we have to > handle all sections. This would have caught subtle breakage such as > 7de3b27bac47da9de08409df1d69664acbb72197 at build-time. > > Also bring some wayward sections into the fold: > - .text.hot and

[PATCH] powerpc: link error on orphan sections

2016-10-12 Thread Nicholas Piggin
Add --orphan-handling=error to final link flags. This ensures we have to handle all sections. This would have caught subtle breakage such as 7de3b27bac47da9de08409df1d69664acbb72197 at build-time. Also bring some wayward sections into the fold: - .text.hot and .text.unlikely are compiler generated