* [PATCH 1/2] kbuild: remove ARCH=sh64 support from top Makefile @ 2021-05-01 17:24 Masahiro Yamada 2021-05-01 17:24 ` [PATCH 2/2] arch: use cross_compiling to check whether it is a cross build or not Masahiro Yamada 2021-05-01 21:18 ` [PATCH 1/2] kbuild: remove ARCH=sh64 support from top Makefile Arnd Bergmann 0 siblings, 2 replies; 8+ messages in thread From: Masahiro Yamada @ 2021-05-01 17:24 UTC (permalink / raw) To: linux-kbuild; +Cc: Arnd Bergmann, Masahiro Yamada, Michal Marek, linux-kernel Commit 37744feebc08 ("sh: remove sh5 support") removed the SUPERH64 support entirely. Remove the left-over code from the top Makefile. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> --- Makefile | 5 ----- 1 file changed, 5 deletions(-) diff --git a/Makefile b/Makefile index 3597fd75d5b5..cbf4b18cf51c 100644 --- a/Makefile +++ b/Makefile @@ -399,11 +399,6 @@ ifeq ($(ARCH),sparc64) SRCARCH := sparc endif -# Additional ARCH settings for sh -ifeq ($(ARCH),sh64) - SRCARCH := sh -endif - export cross_compiling := ifneq ($(SRCARCH),$(SUBARCH)) cross_compiling := 1 -- 2.27.0 ^ permalink raw reply related [flat|nested] 8+ messages in thread
* [PATCH 2/2] arch: use cross_compiling to check whether it is a cross build or not 2021-05-01 17:24 [PATCH 1/2] kbuild: remove ARCH=sh64 support from top Makefile Masahiro Yamada @ 2021-05-01 17:24 ` Masahiro Yamada 2021-05-03 12:53 ` Geert Uytterhoeven ` (3 more replies) 2021-05-01 21:18 ` [PATCH 1/2] kbuild: remove ARCH=sh64 support from top Makefile Arnd Bergmann 1 sibling, 4 replies; 8+ messages in thread From: Masahiro Yamada @ 2021-05-01 17:24 UTC (permalink / raw) To: linux-kbuild Cc: Arnd Bergmann, Masahiro Yamada, Chris Zankel, Geert Uytterhoeven, Helge Deller, James E.J. Bottomley, Max Filippov, Rich Felker, Thomas Bogendoerfer, Yoshinori Sato, linux-kernel, linux-m68k, linux-mips, linux-parisc, linux-sh, linux-xtensa 'cross_compiling' is defined by the top Makefile and available for arch Makefiles to check whether it is a cross build or not. A good thing is the variable name 'cross_compiling' is self-documenting. This is a simple replacement for m68k, mips, sh, for which $(ARCH) and $(SRCARCH) always match. No functional change is intended for xtensa, either. This is rather a fix for parisc because arch/parisc/Makefile defines UTS_MATCHINE depending on CONFIG_64BIT, therefore cc-cross-prefix is not working in Kconfig time. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> --- arch/m68k/Makefile | 2 +- arch/mips/Makefile | 2 +- arch/parisc/Makefile | 2 +- arch/sh/Makefile | 2 +- arch/xtensa/Makefile | 6 +----- 5 files changed, 5 insertions(+), 9 deletions(-) diff --git a/arch/m68k/Makefile b/arch/m68k/Makefile index ea14f2046fb4..82620f14124d 100644 --- a/arch/m68k/Makefile +++ b/arch/m68k/Makefile @@ -16,7 +16,7 @@ KBUILD_DEFCONFIG := multi_defconfig -ifneq ($(SUBARCH),$(ARCH)) +ifdef cross_compiling ifeq ($(CROSS_COMPILE),) CROSS_COMPILE := $(call cc-cross-prefix, \ m68k-linux-gnu- m68k-linux- m68k-unknown-linux-gnu-) diff --git a/arch/mips/Makefile b/arch/mips/Makefile index e71d587af49c..258234c35a09 100644 --- a/arch/mips/Makefile +++ b/arch/mips/Makefile @@ -50,7 +50,7 @@ tool-archpref = $(64bit-tool-archpref) UTS_MACHINE := mips64 endif -ifneq ($(SUBARCH),$(ARCH)) +ifdef cross_compiling ifeq ($(CROSS_COMPILE),) CROSS_COMPILE := $(call cc-cross-prefix, $(tool-archpref)-linux- $(tool-archpref)-linux-gnu- $(tool-archpref)-unknown-linux-gnu-) endif diff --git a/arch/parisc/Makefile b/arch/parisc/Makefile index 7d9f71aa829a..aed8ea29268b 100644 --- a/arch/parisc/Makefile +++ b/arch/parisc/Makefile @@ -41,7 +41,7 @@ endif export LD_BFD -ifneq ($(SUBARCH),$(UTS_MACHINE)) +ifdef cross_compiling ifeq ($(CROSS_COMPILE),) CC_SUFFIXES = linux linux-gnu unknown-linux-gnu CROSS_COMPILE := $(call cc-cross-prefix, \ diff --git a/arch/sh/Makefile b/arch/sh/Makefile index 3bcbf52fb30e..44bcb80e791a 100644 --- a/arch/sh/Makefile +++ b/arch/sh/Makefile @@ -9,7 +9,7 @@ # License. See the file "COPYING" in the main directory of this archive # for more details. # -ifneq ($(SUBARCH),$(ARCH)) +ifdef cross_compiling ifeq ($(CROSS_COMPILE),) CROSS_COMPILE := $(call cc-cross-prefix, sh-linux- sh-linux-gnu- sh-unknown-linux-gnu-) endif diff --git a/arch/xtensa/Makefile b/arch/xtensa/Makefile index ba9fee75e675..e9c8f064c44d 100644 --- a/arch/xtensa/Makefile +++ b/arch/xtensa/Makefile @@ -19,12 +19,8 @@ variant-y := $(patsubst "%",%,$(CONFIG_XTENSA_VARIANT_NAME)) VARIANT = $(variant-y) export VARIANT -# Test for cross compiling - ifneq ($(VARIANT),) - COMPILE_ARCH = $(shell uname -m) - - ifneq ($(COMPILE_ARCH), xtensa) + ifdef cross_compiling ifndef CROSS_COMPILE CROSS_COMPILE = xtensa_$(VARIANT)- endif -- 2.27.0 ^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH 2/2] arch: use cross_compiling to check whether it is a cross build or not 2021-05-01 17:24 ` [PATCH 2/2] arch: use cross_compiling to check whether it is a cross build or not Masahiro Yamada @ 2021-05-03 12:53 ` Geert Uytterhoeven 2021-05-03 13:16 ` Helge Deller ` (2 subsequent siblings) 3 siblings, 0 replies; 8+ messages in thread From: Geert Uytterhoeven @ 2021-05-03 12:53 UTC (permalink / raw) To: Masahiro Yamada Cc: linux-kbuild, Arnd Bergmann, Chris Zankel, Helge Deller, James E.J. Bottomley, Max Filippov, Rich Felker, Thomas Bogendoerfer, Yoshinori Sato, Linux Kernel Mailing List, linux-m68k, open list:BROADCOM NVRAM DRIVER, Parisc List, Linux-sh list, open list:TENSILICA XTENSA PORT (xtensa) Hi Yamada-san, On Sat, May 1, 2021 at 7:26 PM Masahiro Yamada <masahiroy@kernel.org> wrote: > 'cross_compiling' is defined by the top Makefile and available for > arch Makefiles to check whether it is a cross build or not. A good > thing is the variable name 'cross_compiling' is self-documenting. > > This is a simple replacement for m68k, mips, sh, for which $(ARCH) > and $(SRCARCH) always match. > > No functional change is intended for xtensa, either. > > This is rather a fix for parisc because arch/parisc/Makefile defines > UTS_MATCHINE depending on CONFIG_64BIT, therefore cc-cross-prefix > is not working in Kconfig time. > > Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> > arch/m68k/Makefile | 2 +- Acked-by: Geert Uytterhoeven <geert@linux-m68k.org> Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 2/2] arch: use cross_compiling to check whether it is a cross build or not 2021-05-01 17:24 ` [PATCH 2/2] arch: use cross_compiling to check whether it is a cross build or not Masahiro Yamada 2021-05-03 12:53 ` Geert Uytterhoeven @ 2021-05-03 13:16 ` Helge Deller 2021-05-04 9:45 ` Max Filippov 2021-05-06 12:11 ` Rob Landley 3 siblings, 0 replies; 8+ messages in thread From: Helge Deller @ 2021-05-03 13:16 UTC (permalink / raw) To: Masahiro Yamada, linux-kbuild Cc: Arnd Bergmann, James E.J. Bottomley, Thomas Bogendoerfer, Yoshinori Sato, linux-kernel, linux-m68k, linux-parisc, linux-xtensa On 5/1/21 7:24 PM, Masahiro Yamada wrote: > 'cross_compiling' is defined by the top Makefile and available for > arch Makefiles to check whether it is a cross build or not. A good > thing is the variable name 'cross_compiling' is self-documenting. > > This is a simple replacement for m68k, mips, sh, for which $(ARCH) > and $(SRCARCH) always match. > > No functional change is intended for xtensa, either. > > This is rather a fix for parisc because arch/parisc/Makefile defines > UTS_MATCHINE depending on CONFIG_64BIT, therefore cc-cross-prefix > is not working in Kconfig time. > > Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> > arch/m68k/Makefile | 2 +- > arch/mips/Makefile | 2 +- > arch/parisc/Makefile | 2 +- Acked-by: Helge Deller <deller@gmx.de> # parisc Thanks! Helge ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 2/2] arch: use cross_compiling to check whether it is a cross build or not 2021-05-01 17:24 ` [PATCH 2/2] arch: use cross_compiling to check whether it is a cross build or not Masahiro Yamada 2021-05-03 12:53 ` Geert Uytterhoeven 2021-05-03 13:16 ` Helge Deller @ 2021-05-04 9:45 ` Max Filippov 2021-05-06 12:11 ` Rob Landley 3 siblings, 0 replies; 8+ messages in thread From: Max Filippov @ 2021-05-04 9:45 UTC (permalink / raw) To: Masahiro Yamada Cc: linux-kbuild, Arnd Bergmann, Chris Zankel, Geert Uytterhoeven, Helge Deller, James E.J. Bottomley, Rich Felker, Thomas Bogendoerfer, Yoshinori Sato, LKML, open list:M68K ARCHITECTURE, linux-mips, open list:PARISC ARCHITECTURE, open list:SUPERH, open list:TENSILICA XTENSA PORT (xtensa) On Sat, May 1, 2021 at 10:25 AM Masahiro Yamada <masahiroy@kernel.org> wrote: > > 'cross_compiling' is defined by the top Makefile and available for > arch Makefiles to check whether it is a cross build or not. A good > thing is the variable name 'cross_compiling' is self-documenting. > > This is a simple replacement for m68k, mips, sh, for which $(ARCH) > and $(SRCARCH) always match. > > No functional change is intended for xtensa, either. > > This is rather a fix for parisc because arch/parisc/Makefile defines > UTS_MATCHINE depending on CONFIG_64BIT, therefore cc-cross-prefix > is not working in Kconfig time. > > Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> > --- > > arch/m68k/Makefile | 2 +- > arch/mips/Makefile | 2 +- > arch/parisc/Makefile | 2 +- > arch/sh/Makefile | 2 +- > arch/xtensa/Makefile | 6 +----- > 5 files changed, 5 insertions(+), 9 deletions(-) Acked-by: Max Filippov <jcmvbkbc@gmail.com> # xtensa -- Thanks. -- Max ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 2/2] arch: use cross_compiling to check whether it is a cross build or not 2021-05-01 17:24 ` [PATCH 2/2] arch: use cross_compiling to check whether it is a cross build or not Masahiro Yamada ` (2 preceding siblings ...) 2021-05-04 9:45 ` Max Filippov @ 2021-05-06 12:11 ` Rob Landley 3 siblings, 0 replies; 8+ messages in thread From: Rob Landley @ 2021-05-06 12:11 UTC (permalink / raw) To: Masahiro Yamada, linux-kbuild Cc: Arnd Bergmann, Chris Zankel, Geert Uytterhoeven, Helge Deller, James E.J. Bottomley, Max Filippov, Rich Felker, Thomas Bogendoerfer, Yoshinori Sato, linux-kernel, linux-m68k, linux-mips, linux-parisc, linux-sh, linux-xtensa On 5/1/21 12:24 PM, Masahiro Yamada wrote: > 'cross_compiling' is defined by the top Makefile and available for > arch Makefiles to check whether it is a cross build or not. A good > thing is the variable name 'cross_compiling' is self-documenting. > > This is a simple replacement for m68k, mips, sh, for which $(ARCH) > and $(SRCARCH) always match. > > No functional change is intended for xtensa, either. > > This is rather a fix for parisc because arch/parisc/Makefile defines > UTS_MATCHINE depending on CONFIG_64BIT, therefore cc-cross-prefix > is not working in Kconfig time. > > Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Tried the patch in my sh build, the result built and booted. Tested-by: Rob Landley <rob@landley.net> Rob ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 1/2] kbuild: remove ARCH=sh64 support from top Makefile 2021-05-01 17:24 [PATCH 1/2] kbuild: remove ARCH=sh64 support from top Makefile Masahiro Yamada 2021-05-01 17:24 ` [PATCH 2/2] arch: use cross_compiling to check whether it is a cross build or not Masahiro Yamada @ 2021-05-01 21:18 ` Arnd Bergmann 2021-05-05 17:47 ` Masahiro Yamada 1 sibling, 1 reply; 8+ messages in thread From: Arnd Bergmann @ 2021-05-01 21:18 UTC (permalink / raw) To: Masahiro Yamada Cc: Linux Kbuild mailing list, Michal Marek, Linux Kernel Mailing List On Sat, May 1, 2021 at 7:26 PM Masahiro Yamada <masahiroy@kernel.org> wrote: > > Commit 37744feebc08 ("sh: remove sh5 support") removed the SUPERH64 > support entirely. > > Remove the left-over code from the top Makefile. > > Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Good catch! Acked-by: Arnd Bergmann <arnd@arndb.de> ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 1/2] kbuild: remove ARCH=sh64 support from top Makefile 2021-05-01 21:18 ` [PATCH 1/2] kbuild: remove ARCH=sh64 support from top Makefile Arnd Bergmann @ 2021-05-05 17:47 ` Masahiro Yamada 0 siblings, 0 replies; 8+ messages in thread From: Masahiro Yamada @ 2021-05-05 17:47 UTC (permalink / raw) To: Arnd Bergmann Cc: Linux Kbuild mailing list, Michal Marek, Linux Kernel Mailing List On Sun, May 2, 2021 at 6:19 AM Arnd Bergmann <arnd@arndb.de> wrote: > > On Sat, May 1, 2021 at 7:26 PM Masahiro Yamada <masahiroy@kernel.org> wrote: > > > > Commit 37744feebc08 ("sh: remove sh5 support") removed the SUPERH64 > > support entirely. > > > > Remove the left-over code from the top Makefile. > > > > Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> > > Good catch! > > Acked-by: Arnd Bergmann <arnd@arndb.de> Applied to linux-kbuild. -- Best Regards Masahiro Yamada ^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2021-05-06 11:56 UTC | newest] Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2021-05-01 17:24 [PATCH 1/2] kbuild: remove ARCH=sh64 support from top Makefile Masahiro Yamada 2021-05-01 17:24 ` [PATCH 2/2] arch: use cross_compiling to check whether it is a cross build or not Masahiro Yamada 2021-05-03 12:53 ` Geert Uytterhoeven 2021-05-03 13:16 ` Helge Deller 2021-05-04 9:45 ` Max Filippov 2021-05-06 12:11 ` Rob Landley 2021-05-01 21:18 ` [PATCH 1/2] kbuild: remove ARCH=sh64 support from top Makefile Arnd Bergmann 2021-05-05 17:47 ` Masahiro Yamada
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).