All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] fix ppc64 build failure on fedora
@ 2009-09-17 17:41 Kyle McMartin
  2009-09-17 17:57 ` Kyle McMartin
  2009-09-18  1:50 ` Benjamin Herrenschmidt
  0 siblings, 2 replies; 4+ messages in thread
From: Kyle McMartin @ 2009-09-17 17:41 UTC (permalink / raw)
  To: linuxppc-dev; +Cc: linux-kernel

From: Kyle McMartin <kyle@redhat.com>

For some reason or another (newer gcc?) on Fedora 12 koji builders we're
seeing _restgpr0_$n symbols instead of _restgpr_$n as handled in the
prom_init_check.sh file:
Checking prom_init.o symbol '_restgpr0_14'
Error: External symbol '_restgpr0_14' referenced from prom_init.c
Checking prom_init.o symbol '_restgpr0_17'

Add cases to handle this to the filter portion of the script.

Signed-off-by: Kyle McMartin <kyle@redhat.com>
---

diff --git a/arch/powerpc/kernel/prom_init_check.sh b/arch/powerpc/kernel/prom_init_check.sh
index 1ac136b..9f82f49 100644
--- a/arch/powerpc/kernel/prom_init_check.sh
+++ b/arch/powerpc/kernel/prom_init_check.sh
@@ -52,12 +52,18 @@ do
 	if [ "${UNDEF:0:9}" = "_restgpr_" ]; then
 		OK=1
 	fi
+	if [ "${UNDEF:0:10}" = "_restgpr0_" ]; then
+		OK=1
+	fi
 	if [ "${UNDEF:0:11}" = "_rest32gpr_" ]; then
 		OK=1
 	fi
 	if [ "${UNDEF:0:9}" = "_savegpr_" ]; then
 		OK=1
 	fi
+	if [ "${UNDEF:0:10}" = "_savegpr0_" ]; then
+		OK=1
+	fi
 	if [ "${UNDEF:0:11}" = "_save32gpr_" ]; then
 		OK=1
 	fi

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] fix ppc64 build failure on fedora
  2009-09-17 17:41 [PATCH] fix ppc64 build failure on fedora Kyle McMartin
@ 2009-09-17 17:57 ` Kyle McMartin
  2009-09-18  1:50 ` Benjamin Herrenschmidt
  1 sibling, 0 replies; 4+ messages in thread
From: Kyle McMartin @ 2009-09-17 17:57 UTC (permalink / raw)
  To: Kyle McMartin; +Cc: linuxppc-dev, linux-kernel

On Thu, Sep 17, 2009 at 01:41:44PM -0400, Kyle McMartin wrote:
> For some reason or another (newer gcc?) on Fedora 12 koji builders we're
> seeing _restgpr0_$n symbols instead of _restgpr_$n as handled in the
> prom_init_check.sh file:
> Checking prom_init.o symbol '_restgpr0_14'
> Error: External symbol '_restgpr0_14' referenced from prom_init.c
> Checking prom_init.o symbol '_restgpr0_17'
> 
> Add cases to handle this to the filter portion of the script.
> 

Sorry, after reading the gcc code for this, I've realized this is
clearly wrong and must be a toolchain defect...

Apologies for the noise.

cheers, Kyle

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] fix ppc64 build failure on fedora
  2009-09-17 17:41 [PATCH] fix ppc64 build failure on fedora Kyle McMartin
  2009-09-17 17:57 ` Kyle McMartin
@ 2009-09-18  1:50 ` Benjamin Herrenschmidt
  2009-09-18  2:21   ` Kyle McMartin
  1 sibling, 1 reply; 4+ messages in thread
From: Benjamin Herrenschmidt @ 2009-09-18  1:50 UTC (permalink / raw)
  To: Kyle McMartin; +Cc: linuxppc-dev, linux-kernel

On Thu, 2009-09-17 at 13:41 -0400, Kyle McMartin wrote:
> From: Kyle McMartin <kyle@redhat.com>
> 
> For some reason or another (newer gcc?) on Fedora 12 koji builders we're
> seeing _restgpr0_$n symbols instead of _restgpr_$n as handled in the
> prom_init_check.sh file:
> Checking prom_init.o symbol '_restgpr0_14'
> Error: External symbol '_restgpr0_14' referenced from prom_init.c
> Checking prom_init.o symbol '_restgpr0_17'
> 
> Add cases to handle this to the filter portion of the script.

My concern tho is if one of thse is actually called ... we implement
them in arch/powerpc/lib/crtsaveres.S but with the "other" names..

Ben.

> Signed-off-by: Kyle McMartin <kyle@redhat.com>
> ---
> 
> diff --git a/arch/powerpc/kernel/prom_init_check.sh b/arch/powerpc/kernel/prom_init_check.sh
> index 1ac136b..9f82f49 100644
> --- a/arch/powerpc/kernel/prom_init_check.sh
> +++ b/arch/powerpc/kernel/prom_init_check.sh
> @@ -52,12 +52,18 @@ do
>  	if [ "${UNDEF:0:9}" = "_restgpr_" ]; then
>  		OK=1
>  	fi
> +	if [ "${UNDEF:0:10}" = "_restgpr0_" ]; then
> +		OK=1
> +	fi
>  	if [ "${UNDEF:0:11}" = "_rest32gpr_" ]; then
>  		OK=1
>  	fi
>  	if [ "${UNDEF:0:9}" = "_savegpr_" ]; then
>  		OK=1
>  	fi
> +	if [ "${UNDEF:0:10}" = "_savegpr0_" ]; then
> +		OK=1
> +	fi
>  	if [ "${UNDEF:0:11}" = "_save32gpr_" ]; then
>  		OK=1
>  	fi
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/linuxppc-dev


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] fix ppc64 build failure on fedora
  2009-09-18  1:50 ` Benjamin Herrenschmidt
@ 2009-09-18  2:21   ` Kyle McMartin
  0 siblings, 0 replies; 4+ messages in thread
From: Kyle McMartin @ 2009-09-18  2:21 UTC (permalink / raw)
  To: Benjamin Herrenschmidt; +Cc: Kyle McMartin, linuxppc-dev, linux-kernel

On Fri, Sep 18, 2009 at 11:50:06AM +1000, Benjamin Herrenschmidt wrote:
> On Thu, 2009-09-17 at 13:41 -0400, Kyle McMartin wrote:
> > From: Kyle McMartin <kyle@redhat.com>
> > 
> > For some reason or another (newer gcc?) on Fedora 12 koji builders we're
> > seeing _restgpr0_$n symbols instead of _restgpr_$n as handled in the
> > prom_init_check.sh file:
> > Checking prom_init.o symbol '_restgpr0_14'
> > Error: External symbol '_restgpr0_14' referenced from prom_init.c
> > Checking prom_init.o symbol '_restgpr0_17'
> > 
> > Add cases to handle this to the filter portion of the script.
> 
> My concern tho is if one of thse is actually called ... we implement
> them in arch/powerpc/lib/crtsaveres.S but with the "other" names..
> 

Sorry, this appears to be a GCC "feature" introduced in gcc4.5 which is
generating out of line save/restore on ppc64 at -Os. Thanks to Jakub's
suggestion I ended up working around this by building ppc with -O2 for
now (CC_OPTIMIZE_FOR_SIZE)

In any case, according to the gcc "docs" for this, these functions are
supposed to be provided by the linker in the ppc64 case, so it wasn't
correct to try and add them.

I believe Alan Modra said he'd look at the ld issue with regards to
this.

cheers, Kyle

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-09-18  2:21 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-09-17 17:41 [PATCH] fix ppc64 build failure on fedora Kyle McMartin
2009-09-17 17:57 ` Kyle McMartin
2009-09-18  1:50 ` Benjamin Herrenschmidt
2009-09-18  2:21   ` Kyle McMartin

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.