I'm having trouble cross compiling on an up-to-date x64_64 F20 machine.
make CROSS_COMPILE=powerpc64-linux-gnu- ARCH=powerpc drivers/dma/ppc4xx/adma.o CHK include/config/kernel.release CHK include/generated/uapi/linux/version.h CHK include/generated/utsrelease.h CALL scripts/checksyscalls.sh CC drivers/dma/ppc4xx/adma.o {standard input}: Assembler messages: {standard input}:4475: Error: junk at end of line: `1' {standard input}:4616: Error: junk at end of line: `1' {standard input}:4626: Error: junk at end of line: `1' {standard input}:4649: Error: junk at end of line: `1' make[1]: *** [drivers/dma/ppc4xx/adma.o] Error 1 make: *** [drivers/dma/ppc4xx/adma.o] Error 2
make CROSS_COMPILE=powerpc64-linux-gnu- ARCH=powerpc CFLAGS_adma.o="-S" drivers/dma/ppc4xx/adma.o CHK include/config/kernel.release CHK include/generated/uapi/linux/version.h CHK include/generated/utsrelease.h CALL scripts/checksyscalls.sh CC drivers/dma/ppc4xx/adma.o
sed -n -e "4475p; 4616p; 4626p; 4649p" drivers/dma/ppc4xx/adma.o mfcr 10,1 mfcr 10,1 mfcr 10,1 mfcr 10,1
Anyone else seeing this? Is powerpc64-linux-gnu-gcc choking on the assembler it generates itself, or am I doing something wrong?
Paul Bolle
On Fri, Jan 30, 2015 at 8:01 AM, Paul Bolle pebolle@tiscali.nl wrote:
I'm having trouble cross compiling on an up-to-date x64_64 F20 machine.
make CROSS_COMPILE=powerpc64-linux-gnu- ARCH=powerpc drivers/dma/ppc4xx/adma.o CHK include/config/kernel.release CHK include/generated/uapi/linux/version.h CHK include/generated/utsrelease.h CALL scripts/checksyscalls.sh CC drivers/dma/ppc4xx/adma.o {standard input}: Assembler messages: {standard input}:4475: Error: junk at end of line: `1' {standard input}:4616: Error: junk at end of line: `1' {standard input}:4626: Error: junk at end of line: `1' {standard input}:4649: Error: junk at end of line: `1' make[1]: *** [drivers/dma/ppc4xx/adma.o] Error 1 make: *** [drivers/dma/ppc4xx/adma.o] Error 2
You're using a 64-bit compiler to build something that only works on a 32-bit machine. It uses DCRs, which are even more specific to powerpc4xx. Are you trying to build a kernel that works on ppc4xx? If not, just turn the driver off.
make CROSS_COMPILE=powerpc64-linux-gnu- ARCH=powerpc CFLAGS_adma.o="-S" drivers/dma/ppc4xx/adma.o CHK include/config/kernel.release CHK include/generated/uapi/linux/version.h CHK include/generated/utsrelease.h CALL scripts/checksyscalls.sh CC drivers/dma/ppc4xx/adma.o
sed -n -e "4475p; 4616p; 4626p; 4649p" drivers/dma/ppc4xx/adma.o mfcr 10,1 mfcr 10,1 mfcr 10,1 mfcr 10,1
Anyone else seeing this? Is powerpc64-linux-gnu-gcc choking on the assembler it generates itself, or am I doing something wrong?
Probably depends on a lot of various factors. Like how the compiler was built and what flags are being passed. Using V=1 would get you the full gcc invocation.
josh
On Fri, 2015-01-30 at 08:14 -0500, Josh Boyer wrote:
On Fri, Jan 30, 2015 at 8:01 AM, Paul Bolle pebolle@tiscali.nl wrote:
I'm having trouble cross compiling on an up-to-date x64_64 F20 machine.
make CROSS_COMPILE=powerpc64-linux-gnu- ARCH=powerpc drivers/dma/ppc4xx/adma.o CHK include/config/kernel.release CHK include/generated/uapi/linux/version.h CHK include/generated/utsrelease.h CALL scripts/checksyscalls.sh CC drivers/dma/ppc4xx/adma.o {standard input}: Assembler messages: {standard input}:4475: Error: junk at end of line: `1' {standard input}:4616: Error: junk at end of line: `1' {standard input}:4626: Error: junk at end of line: `1' {standard input}:4649: Error: junk at end of line: `1' make[1]: *** [drivers/dma/ppc4xx/adma.o] Error 1 make: *** [drivers/dma/ppc4xx/adma.o] Error 2
You're using a 64-bit compiler to build something that only works on a 32-bit machine. It uses DCRs, which are even more specific to powerpc4xx.
I see. ppc32 is dead and buried for Fedora, isn't it?
Are you trying to build a kernel that works on ppc4xx? If not, just turn the driver off.
I'm only cleaning up some (surprise!) Kconfig cruft that happens to be found in drivers/dma/ppc4xx/adma.c. And I didn't want to submit this eyeball tested only.
make CROSS_COMPILE=powerpc64-linux-gnu- ARCH=powerpc CFLAGS_adma.o="-S" drivers/dma/ppc4xx/adma.o CHK include/config/kernel.release CHK include/generated/uapi/linux/version.h CHK include/generated/utsrelease.h CALL scripts/checksyscalls.sh CC drivers/dma/ppc4xx/adma.o
sed -n -e "4475p; 4616p; 4626p; 4649p" drivers/dma/ppc4xx/adma.o mfcr 10,1 mfcr 10,1 mfcr 10,1 mfcr 10,1
Anyone else seeing this? Is powerpc64-linux-gnu-gcc choking on the assembler it generates itself, or am I doing something wrong?
Probably depends on a lot of various factors. Like how the compiler was built and what flags are being passed. Using V=1 would get you the full gcc invocation.
So does drivers/dma/ppc4xx/.adma.o.cmd, doesn't it? But, either way, I guess I'll just have to submit this untested and let the powerpc maintainers decide whether that's worth the risk. (I seem to remember that I removed support for an entire powerpc board, or whatever, without build testing and no one started to bark. Maybe I'll be that lucky this time too.)
Thanks!
Paul Bolle
On Fri, Jan 30, 2015 at 8:27 AM, Paul Bolle pebolle@tiscali.nl wrote:
On Fri, 2015-01-30 at 08:14 -0500, Josh Boyer wrote:
On Fri, Jan 30, 2015 at 8:01 AM, Paul Bolle pebolle@tiscali.nl wrote:
I'm having trouble cross compiling on an up-to-date x64_64 F20 machine.
make CROSS_COMPILE=powerpc64-linux-gnu- ARCH=powerpc drivers/dma/ppc4xx/adma.o CHK include/config/kernel.release CHK include/generated/uapi/linux/version.h CHK include/generated/utsrelease.h CALL scripts/checksyscalls.sh CC drivers/dma/ppc4xx/adma.o {standard input}: Assembler messages: {standard input}:4475: Error: junk at end of line: `1' {standard input}:4616: Error: junk at end of line: `1' {standard input}:4626: Error: junk at end of line: `1' {standard input}:4649: Error: junk at end of line: `1' make[1]: *** [drivers/dma/ppc4xx/adma.o] Error 1 make: *** [drivers/dma/ppc4xx/adma.o] Error 2
You're using a 64-bit compiler to build something that only works on a 32-bit machine. It uses DCRs, which are even more specific to powerpc4xx.
I see. ppc32 is dead and buried for Fedora, isn't it?
Yep. Even when it was alive, Fedora didn't support ppc4xx as it's a very special snowflake of ppc.
Are you trying to build a kernel that works on ppc4xx? If not, just turn the driver off.
I'm only cleaning up some (surprise!) Kconfig cruft that happens to be found in drivers/dma/ppc4xx/adma.c. And I didn't want to submit this eyeball tested only.
OK.
make CROSS_COMPILE=powerpc64-linux-gnu- ARCH=powerpc CFLAGS_adma.o="-S" drivers/dma/ppc4xx/adma.o CHK include/config/kernel.release CHK include/generated/uapi/linux/version.h CHK include/generated/utsrelease.h CALL scripts/checksyscalls.sh CC drivers/dma/ppc4xx/adma.o
sed -n -e "4475p; 4616p; 4626p; 4649p" drivers/dma/ppc4xx/adma.o mfcr 10,1 mfcr 10,1 mfcr 10,1 mfcr 10,1
Anyone else seeing this? Is powerpc64-linux-gnu-gcc choking on the assembler it generates itself, or am I doing something wrong?
Probably depends on a lot of various factors. Like how the compiler was built and what flags are being passed. Using V=1 would get you the full gcc invocation.
So does drivers/dma/ppc4xx/.adma.o.cmd, doesn't it? But, either way, I
Oh, yeah.
guess I'll just have to submit this untested and let the powerpc maintainers decide whether that's worth the risk. (I seem to remember that I removed support for an entire powerpc board, or whatever, without build testing and no one started to bark. Maybe I'll be that lucky this time too.)
As the former upstream ppc4xx maintainer, feel free to CC me on your patch. The entire sub-arch is fairly dead now, so I don't think there will be many issues.
josh
On Fri, Jan 30, 2015 at 02:01:57PM +0100, Paul Bolle wrote:
I'm having trouble cross compiling on an up-to-date x64_64 F20 machine.
make CROSS_COMPILE=powerpc64-linux-gnu- ARCH=powerpc drivers/dma/ppc4xx/adma.o CHK include/config/kernel.release CHK include/generated/uapi/linux/version.h CHK include/generated/utsrelease.h CALL scripts/checksyscalls.sh CC drivers/dma/ppc4xx/adma.o {standard input}: Assembler messages: {standard input}:4475: Error: junk at end of line: `1' {standard input}:4616: Error: junk at end of line: `1' {standard input}:4626: Error: junk at end of line: `1' {standard input}:4649: Error: junk at end of line: `1' make[1]: *** [drivers/dma/ppc4xx/adma.o] Error 1 make: *** [drivers/dma/ppc4xx/adma.o] Error 2
make CROSS_COMPILE=powerpc64-linux-gnu- ARCH=powerpc CFLAGS_adma.o="-S" drivers/dma/ppc4xx/adma.o CHK include/config/kernel.release CHK include/generated/uapi/linux/version.h CHK include/generated/utsrelease.h CALL scripts/checksyscalls.sh CC drivers/dma/ppc4xx/adma.o
sed -n -e "4475p; 4616p; 4626p; 4649p" drivers/dma/ppc4xx/adma.o mfcr 10,1 mfcr 10,1 mfcr 10,1 mfcr 10,1
Anyone else seeing this? Is powerpc64-linux-gnu-gcc choking on the assembler it generates itself, or am I doing something wrong?
Sorry to get to the party late but I just grabbed: https://www.kernel.org/pub/tools/crosstool/files/bin/x86_64/4.8.0/x86_64-gcc...
and built adma.o without issue.
I used 44x/katmai_defconfig with the following additions. +CONFIG_DMADEVICES=y +CONFIG_AMCC_PPC440SPE_ADMA=y
Yours Tony.
[Added David Howells.]
On Mon, 2015-02-02 at 09:29 +1100, Tony Breeds wrote:
Sorry to get to the party late but I just grabbed: https://www.kernel.org/pub/tools/crosstool/files/bin/x86_64/4.8.0/x86_64-gcc...
and built adma.o without issue.
I used 44x/katmai_defconfig with the following additions. +CONFIG_DMADEVICES=y +CONFIG_AMCC_PPC440SPE_ADMA=y
So I downgraded to cross-gcc-common-4.8.2-2.fc20 and gcc-powerpc64-linux-gnu-4.8.2-2.fc20 (not sure if that version was ever released but I downloaded it from Koji anyhow). Result is comparable to the result I got with the current version of those packages:
make CROSS_COMPILE=powerpc64-linux-gnu- ARCH=powerpc drivers/dma/ppc4xx/adma.o [...] {standard input}: Assembler messages: {standard input}:2122: Error: junk at end of line: `128' {standard input}:2367: Error: junk at end of line: `128' {standard input}:5136: Error: junk at end of line: `1' {standard input}:5165: Error: junk at end of line: `1' {standard input}:5174: Error: junk at end of line: `1' make[1]: *** [drivers/dma/ppc4xx/adma.o] Error 1 make: *** [drivers/dma/ppc4xx/adma.o] Error 2
make CROSS_COMPILE=powerpc64-linux-gnu- ARCH=powerpc CFLAGS_adma.o="-S" drivers/dma/ppc4xx/adma.o CHK include/config/kernel.release CHK include/generated/uapi/linux/version.h CHK include/generated/utsrelease.h CALL scripts/checksyscalls.sh CC drivers/dma/ppc4xx/adma.o
sed -n -e "2122p; 2367p; 5136p; 5165p; 5174p" drivers/dma/ppc4xx/adma.o mfcr 9,128 mfcr 9,128 mfcr 9,1 mfcr 9,1 mfcr 9,1
So this is apparently not some gcc regression. Now Fedora doesn't care anymore about PPC32. On the other hand it does provide _kernel_ cross builders for almost all current kernel architectures. So apparently Fedora hopes to cover as many kernel builds as is possible. Did I get that right?
So would it be worth David's (mostly) and my (a little) time to try to get at least 32 bit PPC code to build?
Paul Bolle
kernel@lists.fedoraproject.org