mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <sha@pengutronix.de>
To: Ahmad Fatoum <a.fatoum@pengutronix.de>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH 1/2] ARM: replace CONFIG_CPU_V8 with CONFIG_CPU_64 in Makefile
Date: Thu, 8 Jun 2023 08:32:34 +0200	[thread overview]
Message-ID: <20230608063234.GH18491@pengutronix.de> (raw)
In-Reply-To: <20230607153152.2681009-1-a.fatoum@pengutronix.de>

On Wed, Jun 07, 2023 at 05:31:51PM +0200, Ahmad Fatoum wrote:
> We use CONFIG_CPU_V8 and CONFIG_CPU_64 interchangeably in barebox,
> because we don't yet support any SoCs with ARMv9 and because we always
> target the A64 instruction set on ARMv8 processors.
> 
> In the Makefile where we have decisions dependent on whether we are
> compiling for 64-bit or not, we should rather use CONFIG_CPU_64 though,
> because the same options would likely be applicable to ARMv9 as well.
> 
> Given that the follow-up commit will introduce a number of
> CONFIG_CPU_32, let's replace the CONFIG_CPU_V8 symbols with
> CONFIG_CPU_64 for symmetry. No functional change.
> 
> Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
> ---
>  arch/arm/Makefile | 14 +++++++-------
>  1 file changed, 7 insertions(+), 7 deletions(-)

Applied, thanks

Sascha

> 
> diff --git a/arch/arm/Makefile b/arch/arm/Makefile
> index 35ebc70f44e2..926af7387f7f 100644
> --- a/arch/arm/Makefile
> +++ b/arch/arm/Makefile
> @@ -4,7 +4,7 @@ KBUILD_DEFCONFIG := multi_v8_defconfig
>  
>  KBUILD_CPPFLAGS	+= -D__ARM__ -fno-strict-aliasing
>  # Explicitly specifiy 32-bit ARM ISA since toolchain default can be -mthumb:
> -ifeq ($(CONFIG_CPU_V8),y)
> +ifeq ($(CONFIG_CPU_64),y)
>  KBUILD_CPPFLAGS	+=$(call cc-option,-maarch64,)
>  else
>  KBUILD_CPPFLAGS	+=$(call cc-option,-marm,)
> @@ -27,14 +27,14 @@ endif
>  # at least some of the code would be executed with MMU off, lets be
>  # conservative and instruct the compiler not to generate any unaligned
>  # accesses
> -ifneq ($(CONFIG_CPU_V8),y)
> +ifneq ($(CONFIG_CPU_64),y)
>  KBUILD_CFLAGS += -mno-unaligned-access
>  else
>  KBUILD_CFLAGS += -mstrict-align
>  endif
>  
>  # Prevent use of floating point and Advanced SIMD registers.
> -ifeq ($(CONFIG_CPU_V8),y)
> +ifeq ($(CONFIG_CPU_64),y)
>  KBUILD_CFLAGS += -mgeneral-regs-only
>  endif
>  
> @@ -54,7 +54,7 @@ tune-$(CONFIG_CPU_ARM920T)	:=-mtune=arm9tdmi
>  tune-$(CONFIG_CPU_ARM926T)	:=-mtune=arm9tdmi
>  tune-$(CONFIG_CPU_XSCALE)	:=$(call cc-option,-mtune=xscale,-mtune=strongarm110) -Wa,-mcpu=xscale
>  
> -ifeq ($(CONFIG_CPU_V8), y)
> +ifeq ($(CONFIG_CPU_64), y)
>  CFLAGS_ABI	:=-mabi=lp64
>  else
>  ifeq ($(CONFIG_AEABI),y)
> @@ -75,7 +75,7 @@ CFLAGS_THUMB2	:=-mthumb $(AFLAGS_AUTOIT) $(AFLAGS_NOWARN)
>  AFLAGS_THUMB2	:=$(CFLAGS_THUMB2) -Wa$(comma)-mthumb
>  endif
>  
> -ifeq ($(CONFIG_CPU_V8), y)
> +ifeq ($(CONFIG_CPU_64), y)
>  KBUILD_CPPFLAGS += $(CFLAGS_ABI) $(arch-y) $(tune-y)
>  KBUILD_AFLAGS   += -include asm/unified.h
>  export S64_32 = 64
> @@ -197,7 +197,7 @@ common-y += arch/arm/boards/ $(MACH)
>  common-y += arch/arm/cpu/
>  common-y += arch/arm/crypto/
>  
> -ifeq ($(CONFIG_CPU_V8), y)
> +ifeq ($(CONFIG_CPU_64), y)
>  common-y += arch/arm/lib64/
>  else
>  common-y += arch/arm/lib32/
> @@ -205,7 +205,7 @@ endif
>  
>  common-$(CONFIG_OFTREE) += arch/arm/dts/
>  
> -ifeq ($(CONFIG_CPU_V8), y)
> +ifeq ($(CONFIG_CPU_64), y)
>  lds-y	:= arch/arm/lib64/barebox.lds
>  else
>  lds-y	:= arch/arm/lib32/barebox.lds
> -- 
> 2.39.2
> 
> 
> 

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |



      parent reply	other threads:[~2023-06-08  6:34 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-07 15:31 Ahmad Fatoum
2023-06-07 15:31 ` [PATCH 2/2] ARM: don't assume 32-bit when no boards are selected Ahmad Fatoum
2023-06-08  8:20   ` Lior Weintraub
2023-06-08  8:46     ` Ahmad Fatoum
2023-06-08  8:59       ` Lior Weintraub
2023-06-08  9:17         ` Ahmad Fatoum
2023-06-08 11:13           ` Lior Weintraub
2023-06-08 12:08             ` Ahmad Fatoum
2023-06-08  6:32 ` Sascha Hauer [this message]

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=20230608063234.GH18491@pengutronix.de \
    --to=sha@pengutronix.de \
    --cc=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox