linux-next: build failure after merge of the akpm-current tree
Subsystems (2)
Hi Andrew,
After merging the akpm-current tree, today's linux-next build (powerpc ppc64_defconfig) failed like this:
powerpc-linux-gcc: error: unrecognized command line option '-m' scripts/Makefile.build:290: recipe for target 'arch/powerpc/purgatory/printf.o' failed
and a few more like that.
Caused by commit
8635b1186486 ("powerpc: add purgatory for kexec_file_load implementation")
I have disabled KEXEC_FILE on powerpc again for now.
From: Stephen Rothwell <[email protected]>
Date: Mon, 5 Sep 2016 19:12:42 +1000
Subject: [PATCH] disable KEXEC_FILE on powerpc for now
--- arch/powerpc/Kconfig | 1 + 1 file changed, 1 insertion(+)
arch/powerpc/Kconfig +1 -0
@@ -467,6 +467,7 @@ config KEXEC_FILE depends on PPC64 depends on CRYPTO=y depends on CRYPTO_SHA256=y + depends on BROKEN help This is a new version of the kexec system call. This call is file based and takes in file descriptors as system call arguments
Signature · 5 lines
2.8.1 -- Cheers, Stephen Rothwell
Hi all,
Quoted 8 lines · On Tue, 20 Sep 2016 16:44:14 +1000 Stephen Rothwell <[email protected]>…
After merging the akpm-current tree, today's linux-next build (powerpc
ppc64_defconfig) failed like this:powerpc-linux-gcc: error: unrecognized command line option '-m'
scripts/Makefile.build:290: recipe for target 'arch/powerpc/purgatory/printf.o' failedand a few more like that.
OK, this is (most likely) caused by the CONFIG_WORD_SIZE -> BITS change interacting with the KEXEC_FILE changes. Tomorrow I will do a better merge conflict resolution patch that fixes all those.
Signature · 2 lines
Cheers, Stephen Rothwell
Hi Michael,
Quoted 2 lines · On Tue, 20 Sep 2016 22:00:32 +1000 Michael Ellerman <[email protected]> wrote:
Ah yep looks like that's the problem, patch below should fix it?
Yeah, I am just going to (logically) run "sed 's/CONFIG_WORD_SIZE/BITS/'" over the tree during the merge of the apm-current tree today.
Quoted 2 lines
I think I'd actually prefer it if purgatory didn't redefine the CFLAGS from scratch, so I'll see if Thiago can do that and send a new version.
That could be better, but there are still some additions of CONFIG_WORD_SIZE elsewhere :-(
Signature · 2 lines
Cheers, Stephen Rothwell
Michael Ellerman
reviewerQuoted 4 lines · Stephen Rothwell
Quoted 2 lines · On Tue, 20 Sep 2016 22:00:32 +1000 Michael Ellerman <[email protected]> wrote:
Ah yep looks like that's the problem, patch below should fix it?
Quoted 8 lines
Yeah, I am just going to (logically) run "sed 's/CONFIG_WORD_SIZE/BITS/'" over the tree during the merge of the apm-current tree today.
Quoted 2 lines
I think I'd actually prefer it if purgatory didn't redefine the CFLAGS from scratch, so I'll see if Thiago can do that and send a new version.
That could be better, but there are still some additions of
CONFIG_WORD_SIZEelsewhere :-(
I don't see any others in yesterday's next?
cheers
Am Mittwoch, 21 September 2016, 10:27:46 schrieb Michael Ellerman:
Quoted 2 lines
Quoted 1 line · Stephen Rothwell
On Tue, 20 Sep 2016 22:00:32 +1000 Michael Ellerman <[email protected]>
Quoted 6 lines · wrote:
Quoted 6 lines
Quoted 1 line
Ah yep looks like that's the problem, patch below should fix it?
Yeah, I am just going to (logically) run "sed 's/CONFIG_WORD_SIZE/BITS/'"
over the tree during the merge of the apm-current tree today.
Quoted 7 lines
Quoted 5 lines
Quoted 2 lines
I think I'd actually prefer it if purgatory didn't redefine the CFLAGS from scratch, so I'll see if Thiago can do that and send a new version.
That could be better, but there are still some additions of
CONFIG_WORD_SIZEelsewhere :-(I don't see any others in yesterday's next?
This kbuild failure is one case:
https://lists.ozlabs.org/pipermail/linuxppc-dev/2016-September/148898.html
elf_util_64.o is only built if CONFIG_WORD_SIZE=64. This is affects the bisectabilty of many patches in the kexec_file_load series. Should I post a new version rebased on powerpc/next?
Signature · 3 lines
[]'s Thiago Jung Bauermann IBM Linux Technology Center
Hi Michael,
Quoted 10 lines · On Wed, 21 Sep 2016 10:27:46 +1000 Michael Ellerman <[email protected]> wrote:
Quoted 7 lines · Stephen Rothwell
Quoted 2 lines · On Tue, 20 Sep 2016 22:00:32 +1000 Michael Ellerman <[email protected]> wrote:
Ah yep looks like that's the problem, patch below should fix it?
Yeah, I am just going to (logically) run "sed 's/CONFIG_WORD_SIZE/BITS/'" over the tree during the merge of the apm-current tree today.
Quoted 7 lines
Quoted 5 lines
Quoted 2 lines
I think I'd actually prefer it if purgatory didn't redefine the CFLAGS from scratch, so I'll see if Thiago can do that and send a new version.
That could be better, but there are still some additions of
CONFIG_WORD_SIZEelsewhere :-(I don't see any others in yesterday's next?
I fixed the other one I found as it caused a build failure as well but was more obvious (and I had had time to think about what was happening).
Signature · 2 lines
Cheers, Stephen Rothwell
Am Dienstag, 20 September 2016, 22:00:32 schrieb Michael Ellerman:
Quoted 2 lines
Quoted 1 line · Stephen Rothwell
On Tue, 20 Sep 2016 16:44:14 +1000 Stephen Rothwell
Quoted 9 lines · <[email protected]> wrote:
Quoted 9 lines
Quoted 8 lines
After merging the akpm-current tree, today's linux-next build (powerpc
ppc64_defconfig) failed like this:powerpc-linux-gcc: error: unrecognized command line option '-m'
scripts/Makefile.build:290: recipe for target 'arch/powerpc/purgatory/printf.o' failedand a few more like that.
Quoted 8 lines
Quoted 3 lines
OK, this is (most likely) caused by the
CONFIG_WORD_SIZE-> BITS change interacting with theKEXEC_FILEchanges. Tomorrow I will do a better merge conflict resolution patch that fixes all those.Ah yep looks like that's the problem, patch below should fix it?
I think I'd actually prefer it if purgatory didn't redefine the CFLAGS from scratch, so I'll see if Thiago can do that and send a new version.
I could move the purgatory inside arch/powerpc/boot and use its BOOTCFLAGS. The needs of the purgatory and the boot wrapper are very similar. Would that be better?
Signature · 3 lines
[]'s Thiago Jung Bauermann IBM Linux Technology Center
Hi all,
Quoted 5 lines · On Wed, 21 Sep 2016 09:16:22 +1000 Stephen Rothwell <[email protected]>…
Quoted 2 lines · On Tue, 20 Sep 2016 22:00:32 +1000 Michael Ellerman <[email protected]> wrote:
Ah yep looks like that's the problem, patch below should fix it?
Quoted 8 lines
Yeah, I am just going to (logically) run "sed 's/CONFIG_WORD_SIZE/BITS/'" over the tree during the merge of the apm-current tree today.
Quoted 2 lines
I think I'd actually prefer it if purgatory didn't redefine the CFLAGS from scratch, so I'll see if Thiago can do that and send a new version.
That could be better, but there are still some additions of
CONFIG_WORD_SIZEelsewhere :-(
So here is the relevant parts of the merge resolution for merging the akpm-current tree today.
arch/powerpc/kernel/Makefile +0 -0
@@@ -104,11 -104,12 +104,12 @@@ obj-$(CONFIG_STACKTRACE) += stacktrace. obj-$(CONFIG_SWIOTLB) += dma-swiotlb.o pci64-$(CONFIG_PPC64) += pci_dn.o pci-hotplug.o isa-bridge.o -obj-$(CONFIG_PCI) += pci_$(CONFIG_WORD_SIZE).o $(pci64-y) \ +obj-$(CONFIG_PCI) += pci_$(BITS).o $(pci64-y) \ pci-common.o pci_of_scan.o obj-$(CONFIG_PCI_MSI) += msi.o - obj-$(CONFIG_KEXEC) += machine_kexec.o crash.o \ + obj-$(CONFIG_KEXEC_CORE) += machine_kexec.o crash.o \ - machine_kexec_$(CONFIG_WORD_SIZE).o -obj-$(CONFIG_KEXEC_FILE) += kexec_elf_$(CONFIG_WORD_SIZE).o + machine_kexec_$(BITS).o ++obj-$(CONFIG_KEXEC_FILE) += kexec_elf_$(BITS).o obj-$(CONFIG_AUDIT) += audit.o obj64-$(CONFIG_AUDIT) += compat_audit.o obj-y += iomap.o endif + ifneq ($(CONFIG_MODULES)$(CONFIG_KEXEC_FILE),) -ifeq ($(CONFIG_WORD_SIZE),64) ++ifeq ($(BITS),64) + obj-y += elf_util.o elf_util_64.o + endif + endif + obj64-$(CONFIG_PPC_TRANSACTIONAL_MEM) += tm.o obj-$(CONFIG_PPC64) += $(obj64-y)
arch/powerpc/purgatory/Makefile +0 -0
mode 000000,100644..100644
--- a/arch/powerpc/purgatory/Makefile
+++ b/arch/powerpc/purgatory/Makefile
@@@ -1,0 -1,48 +1,48 @@@
+ OBJECT_FILES_NON_STANDARD := y
+
+ purgatory-y := purgatory.o printf.o string.o v2wrap.o hvCall.o \
+ purgatory-ppc64.o console-ppc64.o crashdump_backup.o \
+ crtsavres.o sha256.o
+
+ targets += $(purgatory-y)
+ PURGATORY_OBJS = $(addprefix $(obj)/,$(purgatory-y))
+
+ LDFLAGS_purgatory.ro := -e purgatory_start -r --no-undefined -nostartfiles \
+ -nostdlib -nodefaultlibs
+ targets += purgatory.ro
+
+ # Default KBUILD_CFLAGS can have -pg option set when FTRACE is enabled. That
+ # in turn leaves some undefined symbols like __fentry__ in purgatory and not
+ # sure how to relocate those. Like kexec-tools, use custom flags.
+
+ KBUILD_CFLAGS := -Wall -Wstrict-prototypes -fno-strict-aliasing \
+ -fno-zero-initialized-in-bss -fno-builtin -ffreestanding \
+ -fno-PIC -fno-PIE -fno-stack-protector -fno-exceptions \
- -msoft-float -MD -Os -m$(CONFIG_WORD_SIZE)
-KBUILD_AFLAGS := -fno-exceptions -msoft-float -m$(CONFIG_WORD_SIZE) \
++ -msoft-float -MD -Os -m$(BITS)
++KBUILD_AFLAGS := -fno-exceptions -msoft-float -m$(BITS) \
+ -D__ASSEMBLY__
+
+ ifeq ($(CONFIG_CPU_LITTLE_ENDIAN),y)
+ KBUILD_CFLAGS += $(call cc-option,-mabi=elfv2,$(call cc-option,-mcall-aixdesc)) \
+ -mlittle-endian
+ KBUILD_AFLAGS += $(call cc-option,-mabi=elfv2) -mlittle-endian
+ else
+ KBUILD_CFLAGS += $(call cc-option,-mcall-aixdesc) -mbig-endian
+ KBUILD_AFLAGS += -mbig-endian
+ endif
+
+ $(obj)/purgatory.ro: $(PURGATORY_OBJS) FORCE
+ $(call if_changed,ld)
+
+ targets += kexec-purgatory.c
+
+ CMD_BIN2C = $(objtree)/scripts/basic/bin2c
+ quiet_cmd_bin2c = BIN2C $@
+ cmd_bin2c = $(CMD_BIN2C) kexec_purgatory < $< > $@
+
+ $(obj)/kexec-purgatory.c: $(obj)/purgatory.ro FORCE
+ $(call if_changed,bin2c)
+ @:
+
+
+ obj-$(CONFIG_KEXEC_FILE) += kexec-purgatory.o
Signature · 2 lines
Cheers, Stephen Rothwell