From: Will Deacon <will.deacon-5wv7dgnIgG8@public.gmane.org>
To: Ard Biesheuvel <ard.biesheuvel-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
Cc: linux-efi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
matt-mF/unelCI9GS6iBeEJttW/XRex20P6io@public.gmane.org,
catalin.marinas-5wv7dgnIgG8@public.gmane.org
Subject: Re: [PATCH] efi: stub: define DISABLE_BRANCH_PROFILING for all architectures
Date: Mon, 4 Jan 2016 12:31:45 +0000 [thread overview]
Message-ID: <20160104123145.GB1616@arm.com> (raw)
In-Reply-To: <1450862968-20222-1-git-send-email-ard.biesheuvel-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
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-5wv7dgnIgG8@public.gmane.org>
> Signed-off-by: Ard Biesheuvel <ard.biesheuvel-QSEj5FYQhm4dnm+yROfE0A@public.gmane.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-5wv7dgnIgG8@public.gmane.org>
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
>
WARNING: multiple messages have this Message-ID (diff)
From: will.deacon@arm.com (Will Deacon)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] efi: stub: define DISABLE_BRANCH_PROFILING for all architectures
Date: Mon, 4 Jan 2016 12:31:45 +0000 [thread overview]
Message-ID: <20160104123145.GB1616@arm.com> (raw)
In-Reply-To: <1450862968-20222-1-git-send-email-ard.biesheuvel@linaro.org>
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
>
next prev parent reply other threads:[~2016-01-04 12:31 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-23 9:29 [PATCH] efi: stub: define DISABLE_BRANCH_PROFILING for all architectures Ard Biesheuvel
2015-12-23 9:29 ` Ard Biesheuvel
[not found] ` <1450862968-20222-1-git-send-email-ard.biesheuvel-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
2015-12-23 9:33 ` Ard Biesheuvel
2015-12-23 9:33 ` Ard Biesheuvel
2016-01-04 12:31 ` Will Deacon [this message]
2016-01-04 12:31 ` Will Deacon
[not found] ` <20160104123145.GB1616-5wv7dgnIgG8@public.gmane.org>
2016-01-05 14:56 ` Ard Biesheuvel
2016-01-05 14:56 ` Ard Biesheuvel
[not found] ` <CAKv+Gu-n-7tk1NXYAbf7+O79gYG82QOsbzLuYG1yX=LSizksWQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2016-01-05 15:39 ` Matt Fleming
2016-01-05 15:39 ` Matt Fleming
[not found] ` <20160105153918.GA2714-mF/unelCI9GS6iBeEJttW/XRex20P6io@public.gmane.org>
2016-01-05 17:51 ` Will Deacon
2016-01-05 17:51 ` Will Deacon
[not found] ` <20160105175114.GG10705-5wv7dgnIgG8@public.gmane.org>
2016-01-06 15:43 ` Will Deacon
2016-01-06 15:43 ` Will Deacon
[not found] ` <20160106154348.GF16580-5wv7dgnIgG8@public.gmane.org>
2016-01-07 14:59 ` Arnd Bergmann
2016-01-07 14:59 ` Arnd Bergmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160104123145.GB1616@arm.com \
--to=will.deacon-5wv7dgnigg8@public.gmane.org \
--cc=ard.biesheuvel-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
--cc=catalin.marinas-5wv7dgnIgG8@public.gmane.org \
--cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
--cc=linux-efi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=matt-mF/unelCI9GS6iBeEJttW/XRex20P6io@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.