Message ID | 1450862968-20222-1-git-send-email-ard.biesheuvel@linaro.org |
---|---|
State | Accepted |
Commit | b523e185bba36164ca48a190f5468c140d815414 |
Headers | show |
On 23 December 2015 at 10:29, Ard Biesheuvel <ard.biesheuvel@linaro.org> wrote: > This moves the DISABLE_BRANCH_PROFILING define from the x86 specific > to the general CFLAGS definition for the stub. This fixes build errors > when building for arm64 with CONFIG_PROFILE_ALL_BRANCHES_ENABLED. > typo here ^^^ > Reported-by: Will Deacon <will.deacon@arm.com> > Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> > --- > drivers/firmware/efi/libstub/Makefile | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/firmware/efi/libstub/Makefile b/drivers/firmware/efi/libstub/Makefile > index 3c0467d3688c..c0ddd1b8dca3 100644 > --- a/drivers/firmware/efi/libstub/Makefile > +++ b/drivers/firmware/efi/libstub/Makefile > @@ -8,7 +8,7 @@ cflags-$(CONFIG_X86_32) := -march=i386 > cflags-$(CONFIG_X86_64) := -mcmodel=small > cflags-$(CONFIG_X86) += -m$(BITS) -D__KERNEL__ $(LINUX_INCLUDE) -O2 \ > -fPIC -fno-strict-aliasing -mno-red-zone \ > - -mno-mmx -mno-sse -DDISABLE_BRANCH_PROFILING > + -mno-mmx -mno-sse > > cflags-$(CONFIG_ARM64) := $(subst -pg,,$(KBUILD_CFLAGS)) > cflags-$(CONFIG_ARM) := $(subst -pg,,$(KBUILD_CFLAGS)) \ > @@ -16,7 +16,7 @@ cflags-$(CONFIG_ARM) := $(subst -pg,,$(KBUILD_CFLAGS)) \ > > cflags-$(CONFIG_EFI_ARMSTUB) += -I$(srctree)/scripts/dtc/libfdt > > -KBUILD_CFLAGS := $(cflags-y) \ > +KBUILD_CFLAGS := $(cflags-y) -DDISABLE_BRANCH_PROFILING \ > $(call cc-option,-ffreestanding) \ > $(call cc-option,-fno-stack-protector) > > -- > 2.5.0 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
On Wed, Dec 23, 2015 at 10:29:28AM +0100, Ard Biesheuvel wrote: > This moves the DISABLE_BRANCH_PROFILING define from the x86 specific > to the general CFLAGS definition for the stub. This fixes build errors > when building for arm64 with CONFIG_PROFILE_ALL_BRANCHES_ENABLED. > > Reported-by: Will Deacon <will.deacon@arm.com> > Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> > --- > drivers/firmware/efi/libstub/Makefile | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) Cheers, Ard. The kernel now builds and boots as an EFI application for me when the dreaded #define if config option is enabled: Tested-by: Will Deacon <will.deacon@arm.com> Will > diff --git a/drivers/firmware/efi/libstub/Makefile b/drivers/firmware/efi/libstub/Makefile > index 3c0467d3688c..c0ddd1b8dca3 100644 > --- a/drivers/firmware/efi/libstub/Makefile > +++ b/drivers/firmware/efi/libstub/Makefile > @@ -8,7 +8,7 @@ cflags-$(CONFIG_X86_32) := -march=i386 > cflags-$(CONFIG_X86_64) := -mcmodel=small > cflags-$(CONFIG_X86) += -m$(BITS) -D__KERNEL__ $(LINUX_INCLUDE) -O2 \ > -fPIC -fno-strict-aliasing -mno-red-zone \ > - -mno-mmx -mno-sse -DDISABLE_BRANCH_PROFILING > + -mno-mmx -mno-sse > > cflags-$(CONFIG_ARM64) := $(subst -pg,,$(KBUILD_CFLAGS)) > cflags-$(CONFIG_ARM) := $(subst -pg,,$(KBUILD_CFLAGS)) \ > @@ -16,7 +16,7 @@ cflags-$(CONFIG_ARM) := $(subst -pg,,$(KBUILD_CFLAGS)) \ > > cflags-$(CONFIG_EFI_ARMSTUB) += -I$(srctree)/scripts/dtc/libfdt > > -KBUILD_CFLAGS := $(cflags-y) \ > +KBUILD_CFLAGS := $(cflags-y) -DDISABLE_BRANCH_PROFILING \ > $(call cc-option,-ffreestanding) \ > $(call cc-option,-fno-stack-protector) > > -- > 2.5.0 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
(+ Arnd) On 4 January 2016 at 13:31, Will Deacon <will.deacon@arm.com> wrote: > On Wed, Dec 23, 2015 at 10:29:28AM +0100, Ard Biesheuvel wrote: >> This moves the DISABLE_BRANCH_PROFILING define from the x86 specific >> to the general CFLAGS definition for the stub. This fixes build errors >> when building for arm64 with CONFIG_PROFILE_ALL_BRANCHES_ENABLED. >> >> Reported-by: Will Deacon <will.deacon@arm.com> >> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> >> --- >> drivers/firmware/efi/libstub/Makefile | 4 ++-- >> 1 file changed, 2 insertions(+), 2 deletions(-) > > Cheers, Ard. The kernel now builds and boots as an EFI application for > me when the dreaded #define if config option is enabled: > > Tested-by: Will Deacon <will.deacon@arm.com> > > Will > @Matt: this is causing randconfig build errors for ARM in -next. Mind if we take this through some other tree? >> diff --git a/drivers/firmware/efi/libstub/Makefile b/drivers/firmware/efi/libstub/Makefile >> index 3c0467d3688c..c0ddd1b8dca3 100644 >> --- a/drivers/firmware/efi/libstub/Makefile >> +++ b/drivers/firmware/efi/libstub/Makefile >> @@ -8,7 +8,7 @@ cflags-$(CONFIG_X86_32) := -march=i386 >> cflags-$(CONFIG_X86_64) := -mcmodel=small >> cflags-$(CONFIG_X86) += -m$(BITS) -D__KERNEL__ $(LINUX_INCLUDE) -O2 \ >> -fPIC -fno-strict-aliasing -mno-red-zone \ >> - -mno-mmx -mno-sse -DDISABLE_BRANCH_PROFILING >> + -mno-mmx -mno-sse >> >> cflags-$(CONFIG_ARM64) := $(subst -pg,,$(KBUILD_CFLAGS)) >> cflags-$(CONFIG_ARM) := $(subst -pg,,$(KBUILD_CFLAGS)) \ >> @@ -16,7 +16,7 @@ cflags-$(CONFIG_ARM) := $(subst -pg,,$(KBUILD_CFLAGS)) \ >> >> cflags-$(CONFIG_EFI_ARMSTUB) += -I$(srctree)/scripts/dtc/libfdt >> >> -KBUILD_CFLAGS := $(cflags-y) \ >> +KBUILD_CFLAGS := $(cflags-y) -DDISABLE_BRANCH_PROFILING \ >> $(call cc-option,-ffreestanding) \ >> $(call cc-option,-fno-stack-protector) >> >> -- >> 2.5.0 >> _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
On Tue, 05 Jan, at 03:56:39PM, Ard Biesheuvel wrote: > (+ Arnd) > > On 4 January 2016 at 13:31, Will Deacon <will.deacon@arm.com> wrote: > > On Wed, Dec 23, 2015 at 10:29:28AM +0100, Ard Biesheuvel wrote: > >> This moves the DISABLE_BRANCH_PROFILING define from the x86 specific > >> to the general CFLAGS definition for the stub. This fixes build errors > >> when building for arm64 with CONFIG_PROFILE_ALL_BRANCHES_ENABLED. > >> > >> Reported-by: Will Deacon <will.deacon@arm.com> > >> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> > >> --- > >> drivers/firmware/efi/libstub/Makefile | 4 ++-- > >> 1 file changed, 2 insertions(+), 2 deletions(-) > > > > Cheers, Ard. The kernel now builds and boots as an EFI application for > > me when the dreaded #define if config option is enabled: > > > > Tested-by: Will Deacon <will.deacon@arm.com> > > > > Will > > > > @Matt: this is causing randconfig build errors for ARM in -next. Mind > if we take this through some other tree? Go ahead. Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
On Tue, Jan 05, 2016 at 03:39:18PM +0000, Matt Fleming wrote: > On Tue, 05 Jan, at 03:56:39PM, Ard Biesheuvel wrote: > > (+ Arnd) > > > > On 4 January 2016 at 13:31, Will Deacon <will.deacon@arm.com> wrote: > > > On Wed, Dec 23, 2015 at 10:29:28AM +0100, Ard Biesheuvel wrote: > > >> This moves the DISABLE_BRANCH_PROFILING define from the x86 specific > > >> to the general CFLAGS definition for the stub. This fixes build errors > > >> when building for arm64 with CONFIG_PROFILE_ALL_BRANCHES_ENABLED. > > >> > > >> Reported-by: Will Deacon <will.deacon@arm.com> > > >> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> > > >> --- > > >> drivers/firmware/efi/libstub/Makefile | 4 ++-- > > >> 1 file changed, 2 insertions(+), 2 deletions(-) > > > > > > Cheers, Ard. The kernel now builds and boots as an EFI application for > > > me when the dreaded #define if config option is enabled: > > > > > > Tested-by: Will Deacon <will.deacon@arm.com> > > > > > > Will > > > > > > > @Matt: this is causing randconfig build errors for ARM in -next. Mind > > if we take this through some other tree? > > Go ahead. > > Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> I can take this via the arm64 tree, unless Arnd wants to queue it in arm-soc. Arnd? Will _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
On Tue, Jan 05, 2016 at 05:51:14PM +0000, Will Deacon wrote: > On Tue, Jan 05, 2016 at 03:39:18PM +0000, Matt Fleming wrote: > > On Tue, 05 Jan, at 03:56:39PM, Ard Biesheuvel wrote: > > > (+ Arnd) > > > > > > On 4 January 2016 at 13:31, Will Deacon <will.deacon@arm.com> wrote: > > > > On Wed, Dec 23, 2015 at 10:29:28AM +0100, Ard Biesheuvel wrote: > > > >> This moves the DISABLE_BRANCH_PROFILING define from the x86 specific > > > >> to the general CFLAGS definition for the stub. This fixes build errors > > > >> when building for arm64 with CONFIG_PROFILE_ALL_BRANCHES_ENABLED. > > > >> > > > >> Reported-by: Will Deacon <will.deacon@arm.com> > > > >> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> > > > >> --- > > > >> drivers/firmware/efi/libstub/Makefile | 4 ++-- > > > >> 1 file changed, 2 insertions(+), 2 deletions(-) > > > > > > > > Cheers, Ard. The kernel now builds and boots as an EFI application for > > > > me when the dreaded #define if config option is enabled: > > > > > > > > Tested-by: Will Deacon <will.deacon@arm.com> > > > > > > > > Will > > > > > > > > > > @Matt: this is causing randconfig build errors for ARM in -next. Mind > > > if we take this through some other tree? > > > > Go ahead. > > > > Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk> > > I can take this via the arm64 tree, unless Arnd wants to queue it in > arm-soc. Arnd? Given that this fixes build errors, I've applied it in the arm64 tree, so it should appear in -next soon. Will _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
On Wednesday 06 January 2016 15:43:49 Will Deacon wrote: > On Tue, Jan 05, 2016 at 05:51:14PM +0000, Will Deacon wrote: > > I can take this via the arm64 tree, unless Arnd wants to queue it in > > arm-soc. Arnd? arm64 tree is fine with me. > Given that this fixes build errors, I've applied it in the arm64 tree, > so it should appear in -next soon. > Thanks, Arnd _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
diff --git a/drivers/firmware/efi/libstub/Makefile b/drivers/firmware/efi/libstub/Makefile index 3c0467d3688c..c0ddd1b8dca3 100644 --- a/drivers/firmware/efi/libstub/Makefile +++ b/drivers/firmware/efi/libstub/Makefile @@ -8,7 +8,7 @@ cflags-$(CONFIG_X86_32) := -march=i386 cflags-$(CONFIG_X86_64) := -mcmodel=small cflags-$(CONFIG_X86) += -m$(BITS) -D__KERNEL__ $(LINUX_INCLUDE) -O2 \ -fPIC -fno-strict-aliasing -mno-red-zone \ - -mno-mmx -mno-sse -DDISABLE_BRANCH_PROFILING + -mno-mmx -mno-sse cflags-$(CONFIG_ARM64) := $(subst -pg,,$(KBUILD_CFLAGS)) cflags-$(CONFIG_ARM) := $(subst -pg,,$(KBUILD_CFLAGS)) \ @@ -16,7 +16,7 @@ cflags-$(CONFIG_ARM) := $(subst -pg,,$(KBUILD_CFLAGS)) \ cflags-$(CONFIG_EFI_ARMSTUB) += -I$(srctree)/scripts/dtc/libfdt -KBUILD_CFLAGS := $(cflags-y) \ +KBUILD_CFLAGS := $(cflags-y) -DDISABLE_BRANCH_PROFILING \ $(call cc-option,-ffreestanding) \ $(call cc-option,-fno-stack-protector)
This moves the DISABLE_BRANCH_PROFILING define from the x86 specific to the general CFLAGS definition for the stub. This fixes build errors when building for arm64 with CONFIG_PROFILE_ALL_BRANCHES_ENABLED. Reported-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> --- drivers/firmware/efi/libstub/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.5.0 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel