Skip to contentSkip to conversation

sh: various doc, build, init fixes

PATCH In review Randy Dunlap 3 participants 34 messages Mar 6, 2023 – Mar 23, 2023

Subsystems (9)
lore
Share & tools
lore

Randy Dunlap

author reviewer
#0 lore raw

v4 cover sh: various doc, build, init fixes

All of these patches have been sent previously, anywhere from one to 3 times. All patches are now called "v4".

This refresh/resend is to assist the new SH maintainer.

[PATCH 1/7 v4] sh: SH2007: drop the bad URL info
[PATCH 2/7 v4] sh: nmi_debug: fix return value of __setup handler [PATCH 3/7 v4] sh: init: use OF_EARLY_FLATTREE for early init [PATCH 4/7 v4] sh: math-emu: fix macro redefined warning [PATCH 5/7 v4] sh: remove sh5/sh64 last fragments
[PATCH 6/7 v4] sh: fix Kconfig entry for NUMA => SMP
[PATCH 7/7 v4] sh: mcount.S: fix build error when PRINTK is not enabled

diffstat:

 Documentation/kbuild/kbuild.rst                           |    1 -
 Documentation/scheduler/sched-arch.rst                    |    2 --
 Documentation/translations/zh_CN/scheduler/sched-arch.rst |    2 --
 arch/sh/Kconfig                                           |    4 ++++
 arch/sh/Kconfig.debug                                     |    2 +-
 arch/sh/boards/Kconfig                                    |    1 -
 arch/sh/kernel/head_32.S                                  |    6 +++---
 arch/sh/kernel/nmi_debug.c                                |    4 ++--
 arch/sh/kernel/setup.c                                    |    4 ++--
 arch/sh/math-emu/sfp-util.h                               |    4 ----
 scripts/checkstack.pl                                     |    7 -------
 tools/perf/arch/common.c                                  |    2 --
 tools/scripts/Makefile.arch                               |    5 -----
 tools/testing/selftests/mm/Makefile                       |    2 +-
 tools/testing/selftests/mm/run_vmtests.sh                 |    2 +-
 15 files changed, 14 insertions(+), 34 deletions(-)
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>
Cc Geert Uytterhoeven <[email protected]>
Cc Hitoshi Mitake <[email protected]>
Cc Frank Rowand <[email protected]>
Cc Arnd Bergmann <[email protected]>
author reviewer
#1 lore raw

PATCH v4 1/7 sh: SH2007: drop the bad URL info

This URL provided is no longer functional, so drop it.

Fixes 3a598264436e ("sh: SH-2007 board support.")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>
Cc Geert Uytterhoeven <[email protected]>
Cc Hitoshi Mitake <[email protected]>

---
v2: skipped
v3: skipped
v4: refresh/rebase and resend

 arch/sh/boards/Kconfig |    1 -
 1 file changed, 1 deletion(-)
arch/sh/boards/Kconfig +0 -1
diff -- a/arch/sh/boards/Kconfig b/arch/sh/boards/Kconfig
@@ -358,7 +358,6 @@ config SH_SH2007
 	  intended for embedded applications.
 	  It has an Ethernet interface (SMC9118), direct connected
 	  Compact Flash socket, two serial ports and PC-104 bus.
-	  More information at <http://sh2000.sh-linux.org>.
 
 config SH_APSH4A3A
 	bool "AP-SH4A-3A"
maintainer Reviewed-by on v4 1/7
#2 lore raw

Re: [PATCH 1/7 v4] sh: SH2007: drop the bad URL info

Quoted 23 lines · Randy Dunlap

This URL provided is no longer functional, so drop it.

Fixes 3a598264436e ("sh: SH-2007 board support.")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>
Cc Geert Uytterhoeven <[email protected]>
Cc Hitoshi Mitake <[email protected]>

---
v2: skipped
v3: skipped
v4: refresh/rebase and resend

 arch/sh/boards/Kconfig |    1 -
 1 file changed, 1 deletion(-)

diff -- a/arch/sh/boards/Kconfig b/arch/sh/boards/Kconfig

arch/sh/boards/Kconfig config SH_SH2007 · line 363

Quoted 7 lines
arch/sh/boards/Kconfig +0 -1
@@ -358,7 +358,6 @@ config SH_SH2007
 	  intended for embedded applications.
 	  It has an Ethernet interface (SMC9118), direct connected
 	  Compact Flash socket, two serial ports and PC-104 bus.
-	  More information at <http://sh2000.sh-linux.org>.
 
 config SH_APSH4A3A
 	bool "AP-SH4A-3A"
Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
author reviewer
#3 lore raw

PATCH v4 2/7 sh: nmi_debug: fix return value of __setup handler

In reply to Randy Dunlap

__setup() handlers should return 1 to obsolete_checksetup() in init/main.c to indicate that the boot option has been handled. A return of 0 causes the boot option/value to be listed as an Unknown kernel parameter and added to init's (limited) argument or environment strings. Also, error return codes don't mean anything to obsolete_checksetup() -- only non-zero (usually 1) or zero. So return 1 from nmi_debug_setup().

Fixes 1e1030dccb10 ("sh: nmi_debug support.")
Link lore.kernel.org/r/[email protected]
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---

v2: add more Cc's;
    refresh and resend;

v3: add Arnd to Cc: list
v4: update Cc: list, refresh & resend

 arch/sh/kernel/nmi_debug.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/sh/kernel/nmi_debug.c +2 -2
diff -- a/arch/sh/kernel/nmi_debug.c b/arch/sh/kernel/nmi_debug.c
@@ -49,7 +49,7 @@ static int __init nmi_debug_setup(char *
 	register_die_notifier(&nmi_debug_nb);
 
 	if (*str != '=')
-		return 0;
+		return 1;
 
 	for (p = str + 1; *p; p = sep + 1) {
 		sep = strchr(p, ',');
@@ -70,6 +70,6 @@ static int __init nmi_debug_setup(char *
 			break;
 	}
 
-	return 0;
+	return 1;
 }
 __setup("nmi_debug", nmi_debug_setup);
maintainer Reviewed-by on v4 2/7
#4 lore raw

Re: [PATCH 2/7 v4] sh: nmi_debug: fix return value of __setup handler

Quoted 39 lines · Randy Dunlap

__setup() handlers should return 1 to obsolete_checksetup() in init/main.c to indicate that the boot option has been handled. A return of 0 causes the boot option/value to be listed as an Unknown kernel parameter and added to init's (limited) argument or environment strings. Also, error return codes don't mean anything to obsolete_checksetup() -- only non-zero (usually 1) or zero. So return 1 from nmi_debug_setup().

Fixes 1e1030dccb10 ("sh: nmi_debug support.")
Link lore.kernel.org/r/[email protected]
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---

v2: add more Cc's;
    refresh and resend;

v3: add Arnd to Cc: list
v4: update Cc: list, refresh & resend

 arch/sh/kernel/nmi_debug.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff -- a/arch/sh/kernel/nmi_debug.c b/arch/sh/kernel/nmi_debug.c

arch/sh/kernel/nmi_debug.c +1 -1
@@ -49,7 +49,7 @@ static int __init nmi_debug_setup(char *
 	register_die_notifier(&nmi_debug_nb);
 
 	if (*str != '=')
-		return 0;
+		return 1;
 
 	for (p = str + 1; *p; p = sep + 1) {
 		sep = strchr(p, ',');

arch/sh/kernel/nmi_debug.c static int __init nmi_debug_setup(char * · line 75

Quoted 7 lines
arch/sh/kernel/nmi_debug.c +1 -1
@@ -70,6 +70,6 @@ static int __init nmi_debug_setup(char *
 			break;
 	}
 
-	return 0;
+	return 1;
 }
 __setup("nmi_debug", nmi_debug_setup);
Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
author reviewer
#5 lore raw

PATCH v4 3/7 sh: init: use OF_EARLY_FLATTREE for early init

In reply to Randy Dunlap

When CONFIG_OF_EARLY_FLATTREE and CONFIG_SH_DEVICE_TREE are not set, SH3 build fails with a call to early_init_dt_scan(), so in arch/sh/kernel/setup.c and arch/sh/kernel/head_32.S, use CONFIG_OF_EARLY_FLATTREE instead of CONFIG_OF_FLATTREE.

Fixes this build error:
../arch/sh/kernel/setup.c: In function 'sh_fdt_init':
../arch/sh/kernel/setup.c:262:26: error: implicit declaration of function 'early_init_dt_scan' [-Werror=implicit-function-declaration]
262 | if (!dt_virt || !early_init_dt_scan(dt_virt)) {

Fixes 03767daa1387 ("sh: fix build regression with CONFIG_OF && !CONFIG_OF_FLATTREE")
Fixes eb6b6930a70f ("sh: fix memory corruption of unflattened device tree")
Cc Frank Rowand <[email protected]>
Cc Rich Felker <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Geert Uytterhoeven <[email protected]>
Cc John Paul Adrian Glaubitz <[email protected]>

---
v2: use Suggested-by: for Rob.
add more Cc's.
v3: skipped
v4: update Cc's, refresh & resend

 arch/sh/kernel/head_32.S |    6 +++---
 arch/sh/kernel/setup.c   |    4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

diff arch/sh/kernel/setup.c arch/sh/kernel/setup.c

arch/sh/kernel/setup.c +2 -2
diff -- a/arch/sh/kernel/setup.c b/arch/sh/kernel/setup.c
@@ -244,7 +244,7 @@ void __init __weak plat_early_device_set
 {
 }
 
-#ifdef CONFIG_OF_FLATTREE
+#ifdef CONFIG_OF_EARLY_FLATTREE
 void __ref sh_fdt_init(phys_addr_t dt_phys)
 {
 	static int done = 0;
@@ -326,7 +326,7 @@ void __init setup_arch(char **cmdline_p)
 	/* Let earlyprintk output early console messages */
 	sh_early_platform_driver_probe("earlyprintk", 1, 1);
 
-#ifdef CONFIG_OF_FLATTREE
+#ifdef CONFIG_OF_EARLY_FLATTREE
 #ifdef CONFIG_USE_BUILTIN_DTB
 	unflatten_and_copy_device_tree();
 #else
arch/sh/kernel/head_32.S +3 -3
diff -- a/arch/sh/kernel/head_32.S b/arch/sh/kernel/head_32.S
@@ -64,7 +64,7 @@ ENTRY(_stext)
 	ldc	r0, r6_bank
 #endif
 
-#ifdef CONFIG_OF_FLATTREE
+#ifdef CONFIG_OF_EARLY_FLATTREE
 	mov	r4, r12		! Store device tree blob pointer in r12
 #endif
 	
@@ -315,7 +315,7 @@ ENTRY(_stext)
 10:		
 #endif
 
-#ifdef CONFIG_OF_FLATTREE
+#ifdef CONFIG_OF_EARLY_FLATTREE
 	mov.l	8f, r0		! Make flat device tree available early.
 	jsr	@r0
 	 mov	r12, r4
@@ -346,7 +346,7 @@ ENTRY(stack_start)
 5:	.long	start_kernel
 6:	.long	cpu_init
 7:	.long	init_thread_union
-#if defined(CONFIG_OF_FLATTREE)
+#if defined(CONFIG_OF_EARLY_FLATTREE)
 8:	.long	sh_fdt_init
 #endif
 
maintainer Reviewed-by on v4 3/7
#6 lore raw

Re: [PATCH 3/7 v4] sh: init: use OF_EARLY_FLATTREE for early init

Quoted 76 lines · Randy Dunlap

When CONFIG_OF_EARLY_FLATTREE and CONFIG_SH_DEVICE_TREE are not set, SH3 build fails with a call to early_init_dt_scan(), so in arch/sh/kernel/setup.c and arch/sh/kernel/head_32.S, use CONFIG_OF_EARLY_FLATTREE instead of CONFIG_OF_FLATTREE.

Fixes this build error:
../arch/sh/kernel/setup.c: In function 'sh_fdt_init':
../arch/sh/kernel/setup.c:262:26: error: implicit declaration of function 'early_init_dt_scan' [-Werror=implicit-function-declaration]
262 | if (!dt_virt || !early_init_dt_scan(dt_virt)) {

Fixes 03767daa1387 ("sh: fix build regression with CONFIG_OF && !CONFIG_OF_FLATTREE")
Fixes eb6b6930a70f ("sh: fix memory corruption of unflattened device tree")
Cc Frank Rowand <[email protected]>
Cc Rich Felker <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Geert Uytterhoeven <[email protected]>
Cc John Paul Adrian Glaubitz <[email protected]>

---
v2: use Suggested-by: for Rob.
add more Cc's.
v3: skipped
v4: update Cc's, refresh & resend

 arch/sh/kernel/head_32.S |    6 +++---
 arch/sh/kernel/setup.c   |    4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

diff arch/sh/kernel/setup.c arch/sh/kernel/setup.c diff -- a/arch/sh/kernel/setup.c b/arch/sh/kernel/setup.c

arch/sh/kernel/setup.c +2 -2
@@ -244,7 +244,7 @@ void __init __weak plat_early_device_set
 {
 }
 
-#ifdef CONFIG_OF_FLATTREE
+#ifdef CONFIG_OF_EARLY_FLATTREE
 void __ref sh_fdt_init(phys_addr_t dt_phys)
 {
 	static int done = 0;
@@ -326,7 +326,7 @@ void __init setup_arch(char **cmdline_p)
 	/* Let earlyprintk output early console messages */
 	sh_early_platform_driver_probe("earlyprintk", 1, 1);
 
-#ifdef CONFIG_OF_FLATTREE
+#ifdef CONFIG_OF_EARLY_FLATTREE
 #ifdef CONFIG_USE_BUILTIN_DTB
 	unflatten_and_copy_device_tree();
 #else

diff -- a/arch/sh/kernel/head_32.S b/arch/sh/kernel/head_32.S

arch/sh/kernel/head_32.S +2 -2
@@ -64,7 +64,7 @@ ENTRY(_stext)
 	ldc	r0, r6_bank
 #endif
 
-#ifdef CONFIG_OF_FLATTREE
+#ifdef CONFIG_OF_EARLY_FLATTREE
 	mov	r4, r12		! Store device tree blob pointer in r12
 #endif
 
@@ -315,7 +315,7 @@ ENTRY(_stext)
 10:		
 #endif
 
-#ifdef CONFIG_OF_FLATTREE
+#ifdef CONFIG_OF_EARLY_FLATTREE
 	mov.l	8f, r0		! Make flat device tree available early.
 	jsr	@r0
 	 mov	r12, r4

arch/sh/kernel/head_32.S ENTRY(stack_start) · line 352

Quoted 8 lines
arch/sh/kernel/head_32.S +1 -1
@@ -346,7 +346,7 @@ ENTRY(stack_start)
 5:	.long	start_kernel
 6:	.long	cpu_init
 7:	.long	init_thread_union
-#if defined(CONFIG_OF_FLATTREE)
+#if defined(CONFIG_OF_EARLY_FLATTREE)
 8:	.long	sh_fdt_init
 #endif
 
Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
author reviewer
#7 lore raw

PATCH v4 4/7 sh: math-emu: fix macro redefined warning

In reply to Randy Dunlap

Fix a warning that was reported by the kernel test robot:

In file included from ../include/math-emu/soft-fp.h:27,

                 from ../arch/sh/math-emu/math.c:22:

../arch/sh/include/asm/sfp-machine.h:17: warning: "__BYTE_ORDER" redefined
17 | #define __BYTE_ORDER __BIG_ENDIAN
In file included from ../arch/sh/math-emu/math.c:21:
../arch/sh/math-emu/sfp-util.h:71: note: this is the location of the previous definition
71 | #define __BYTE_ORDER __LITTLE_ENDIAN

Fixes b929926f01f2 ("sh: define __BIG_ENDIAN for math-emu")
Link lore.kernel.org/r/[email protected]
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: add Reviewed-by Geert,

    rebase to linux-next-20211115

v3: skipped
v4: refresh & resend

 arch/sh/math-emu/sfp-util.h |    4 ----
 1 file changed, 4 deletions(-)
arch/sh/math-emu/sfp-util.h +0 -4
diff -- a/arch/sh/math-emu/sfp-util.h b/arch/sh/math-emu/sfp-util.h
@@ -67,7 +67,3 @@
   } while (0)
 
 #define abort()	return 0
-
-#define __BYTE_ORDER __LITTLE_ENDIAN
-
-
maintainer Reviewed-by on v4 4/7
#8 lore raw

Re: [PATCH 4/7 v4] sh: math-emu: fix macro redefined warning

Quoted 33 lines · Randy Dunlap

Fix a warning that was reported by the kernel test robot:

In file included from ../include/math-emu/soft-fp.h:27,

                 from ../arch/sh/math-emu/math.c:22:

../arch/sh/include/asm/sfp-machine.h:17: warning: "__BYTE_ORDER" redefined
17 | #define __BYTE_ORDER __BIG_ENDIAN
In file included from ../arch/sh/math-emu/math.c:21:
../arch/sh/math-emu/sfp-util.h:71: note: this is the location of the previous definition
71 | #define __BYTE_ORDER __LITTLE_ENDIAN

Fixes b929926f01f2 ("sh: define __BIG_ENDIAN for math-emu")
Link lore.kernel.org/r/[email protected]
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: add Reviewed-by Geert,

    rebase to linux-next-20211115

v3: skipped
v4: refresh & resend

 arch/sh/math-emu/sfp-util.h |    4 ----
 1 file changed, 4 deletions(-)

diff -- a/arch/sh/math-emu/sfp-util.h b/arch/sh/math-emu/sfp-util.h

arch/sh/math-emu/sfp-util.h line 73

Quoted 7 lines
arch/sh/math-emu/sfp-util.h +0 -4
@@ -67,7 +67,3 @@
   } while (0)
 
 #define abort()	return 0
-
-#define __BYTE_ORDER __LITTLE_ENDIAN
-
-
Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
author reviewer
#9 lore raw

PATCH v4 5/7 sh: remove sh5/sh64 last fragments

In reply to Randy Dunlap

A previous patch removed most of the sh5 (sh64) support from the kernel tree. Now remove the last stragglers.

Fixes 37744feebc08 ("sh: remove sh5 support")
Cc Geert Uytterhoeven <[email protected]>
Cc Arnd Bergmann <[email protected]>
Cc Rich Felker <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc John Paul Adrian Glaubitz <[email protected]>

---
v2: update after adding the parisc64 alias to kbuild.rst
v3: skipped
v4: refresh & resend

 Documentation/kbuild/kbuild.rst                           |    1 -
 Documentation/scheduler/sched-arch.rst                    |    2 --
 Documentation/translations/zh_CN/scheduler/sched-arch.rst |    2 --
 scripts/checkstack.pl                                     |    7 -------
 tools/perf/arch/common.c                                  |    2 --
 tools/scripts/Makefile.arch                               |    5 -----
 tools/testing/selftests/mm/Makefile                       |    2 +-
 tools/testing/selftests/mm/run_vmtests.sh                 |    2 +-
 8 files changed, 2 insertions(+), 21 deletions(-)
Documentation/kbuild/kbuild.rst +0 -1
diff -- a/Documentation/kbuild/kbuild.rst b/Documentation/kbuild/kbuild.rst
@@ -161,7 +161,6 @@ But some architectures such as x86 and s
 
 - x86: i386 for 32 bit, x86_64 for 64 bit
 - parisc: parisc64 for 64 bit
-- sh: sh for 32 bit, sh64 for 64 bit
 - sparc: sparc32 for 32 bit, sparc64 for 64 bit
 
 CROSS_COMPILE
Documentation/scheduler/sched-arch.rst +0 -2
diff -- a/Documentation/scheduler/sched-arch.rst b/Documentation/scheduler/sched-arch.rst
@@ -70,7 +70,5 @@ Possible arch problems I found (and eith
 
 ia64 - is safe_halt call racy vs interrupts? (does it sleep?) (See #4a)
 
-sh64 - Is sleeping racy vs interrupts? (See #4a)
-
 sparc - IRQs on at this point(?), change local_irq_save to _disable.
       - TODO: needs secondary CPUs to disable preempt (See #1)
Documentation/translations/zh_CN/scheduler/sched-arch.rst +0 -2
diff -- a/Documentation/translations/zh_CN/scheduler/sched-arch.rst b/Documentation/translations/zh_CN/scheduler/sched-arch.rst
@@ -70,7 +70,5 @@ 我发现的可能的arch问题(并试
 
 ia64 - safe_halt的调用与中断相比,是否很荒谬? (它睡眠了吗) (参考 #4a)
 
-sh64 - 睡眠与中断相比,是否很荒谬? (参考 #4a)
-
 sparc - 在这一点上,IRQ是开着的(?),把local_irq_save改为_disable。
       - 待办事项: 需要第二个CPU来禁用抢占 (参考 #1)
scripts/checkstack.pl +0 -7
diff -- a/scripts/checkstack.pl b/scripts/checkstack.pl
@@ -10,7 +10,6 @@
 #	Mips port by Juan Quintela <[email protected]>
 #	IA64 port via Andreas Dilger
 #	Arm port by Holger Schurig
-#	sh64 port by Paul Mundt
 #	Random bits by Matt Mackall <[email protected]>
 #	M68k port by Geert Uytterhoeven and Andreas Schwab
 #	AArch64, PARISC ports by Kyle McMartin
@@ -100,12 +99,6 @@ my (@stack, $re, $dre, $sub, $x, $xs, $f
 		#  100092:	 e3 f0 ff c8 ff 71	 lay	 %r15,-56(%r15)
 		$re = qr/.*(?:lay|ag?hi).*\%r15,-(([0-9]{2}|[3-9])[0-9]{2})
 		      (?:\(\%r15\))?$/ox;
-	} elsif ($arch =~ /^sh64$/) {
-		#XXX: we only check for the immediate case presently,
-		#     though we will want to check for the movi/sub
-		#     pair for larger users. -- PFM.
-		#a00048e0:       d4fc40f0        addi.l  r15,-240,r15
-		$re = qr/.*addi\.l.*r15,-(([0-9]{2}|[3-9])[0-9]{2}),r15/o;
 	} elsif ($arch eq 'sparc' || $arch eq 'sparc64') {
 		# f0019d10:       9d e3 bf 90     save  %sp, -112, %sp
 		$re = qr/.*save.*%sp, -(([0-9]{2}|[3-9])[0-9]{2}), %sp/o;
tools/perf/arch/common.c +0 -2
diff -- a/tools/perf/arch/common.c b/tools/perf/arch/common.c
@@ -51,9 +51,7 @@ const char *const s390_triplets[] = {
 
 const char *const sh_triplets[] = {
 	"sh-unknown-linux-gnu-",
-	"sh64-unknown-linux-gnu-",
 	"sh-linux-gnu-",
-	"sh64-linux-gnu-",
 	NULL
 };
 
tools/scripts/Makefile.arch +0 -5
diff -- a/tools/scripts/Makefile.arch b/tools/scripts/Makefile.arch
@@ -29,11 +29,6 @@ ifeq ($(ARCH),sparc64)
        SRCARCH := sparc
 endif
 
-# Additional ARCH settings for sh
-ifeq ($(ARCH),sh64)
-       SRCARCH := sh
-endif
-
 # Additional ARCH settings for loongarch
 ifeq ($(ARCH),loongarch32)
        SRCARCH := loongarch
tools/testing/selftests/mm/Makefile +1 -1
diff -- a/tools/testing/selftests/mm/Makefile b/tools/testing/selftests/mm/Makefile
@@ -90,7 +90,7 @@ endif
 
 endif
 
-ifneq (,$(filter $(MACHINE),arm64 ia64 mips64 parisc64 ppc64 riscv64 s390x sh64 sparc64 x86_64))
+ifneq (,$(filter $(MACHINE),arm64 ia64 mips64 parisc64 ppc64 riscv64 s390x sparc64 x86_64))
 TEST_GEN_FILES += va_128TBswitch
 TEST_GEN_FILES += virtual_address_range
 TEST_GEN_FILES += write_to_hugetlbfs
tools/testing/selftests/mm/run_vmtests.sh +1 -1
diff -- a/tools/testing/selftests/mm/run_vmtests.sh b/tools/testing/selftests/mm/run_vmtests.sh
@@ -132,7 +132,7 @@ else
 fi
 
 # filter 64bit architectures
-ARCH64STR="arm64 ia64 mips64 parisc64 ppc64 ppc64le riscv64 s390x sh64 sparc64 x86_64"
+ARCH64STR="arm64 ia64 mips64 parisc64 ppc64 ppc64le riscv64 s390x sparc64 x86_64"
 if [ -z "$ARCH" ]; then
 	ARCH=$(uname -m 2>/dev/null | sed -e 's/aarch64.*/arm64/')
 fi
#10 lore raw

Re: [PATCH 5/7 v4] sh: remove sh5/sh64 last fragments

Hi Randy!

Quoted 31 lines · Randy Dunlap

A previous patch removed most of the sh5 (sh64) support from the kernel tree. Now remove the last stragglers.

Fixes 37744feebc08 ("sh: remove sh5 support")
Cc Geert Uytterhoeven <[email protected]>
Cc Arnd Bergmann <[email protected]>
Cc Rich Felker <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc John Paul Adrian Glaubitz <[email protected]>

---
v2: update after adding the parisc64 alias to kbuild.rst
v3: skipped
v4: refresh & resend

 Documentation/kbuild/kbuild.rst                           |    1 -
 Documentation/scheduler/sched-arch.rst                    |    2 --
 Documentation/translations/zh_CN/scheduler/sched-arch.rst |    2 --
 scripts/checkstack.pl                                     |    7 -------
 tools/perf/arch/common.c                                  |    2 --
 tools/scripts/Makefile.arch                               |    5 -----
 tools/testing/selftests/mm/Makefile                       |    2 +-
 tools/testing/selftests/mm/run_vmtests.sh                 |    2 +-
 8 files changed, 2 insertions(+), 21 deletions(-)

diff -- a/Documentation/kbuild/kbuild.rst b/Documentation/kbuild/kbuild.rst

Documentation/kbuild/kbuild.rst But some architectures such as x86 and s · line 166

Quoted 7 lines
Documentation/kbuild/kbuild.rst +0 -1
@@ -161,7 +161,6 @@ But some architectures such as x86 and s
 
 - x86: i386 for 32 bit, x86_64 for 64 bit
 - parisc: parisc64 for 64 bit
-- sh: sh for 32 bit, sh64 for 64 bit
 - sparc: sparc32 for 32 bit, sparc64 for 64 bit
 
 CROSS_COMPILE

This hunk doesn't apply anymore since the parisc part has been dropped although I can't find the commit for that. Could you rebase your patch, please?

Apologies that I didn't have the time earlier to start looking at this series!

Adrian

Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
author reviewer
#11 lore raw

Re: [PATCH 5/7 v4] sh: remove sh5/sh64 last fragments

Hi--

Quoted 40 lines · John Paul Adrian Glaubitz

Hi Randy!

Quoted 37 lines · Randy Dunlap

A previous patch removed most of the sh5 (sh64) support from the kernel tree. Now remove the last stragglers.

Fixes 37744feebc08 ("sh: remove sh5 support")
Cc Geert Uytterhoeven <[email protected]>
Cc Arnd Bergmann <[email protected]>
Cc Rich Felker <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc John Paul Adrian Glaubitz <[email protected]>

---
v2: update after adding the parisc64 alias to kbuild.rst
v3: skipped
v4: refresh & resend

 Documentation/kbuild/kbuild.rst                           |    1 -
 Documentation/scheduler/sched-arch.rst                    |    2 --
 Documentation/translations/zh_CN/scheduler/sched-arch.rst |    2 --
 scripts/checkstack.pl                                     |    7 -------
 tools/perf/arch/common.c                                  |    2 --
 tools/scripts/Makefile.arch                               |    5 -----
 tools/testing/selftests/mm/Makefile                       |    2 +-
 tools/testing/selftests/mm/run_vmtests.sh                 |    2 +-
 8 files changed, 2 insertions(+), 21 deletions(-)

diff -- a/Documentation/kbuild/kbuild.rst b/Documentation/kbuild/kbuild.rst

Documentation/kbuild/kbuild.rst +0 -1
@@ -161,7 +161,6 @@ But some architectures such as x86 and s
 
 - x86: i386 for 32 bit, x86_64 for 64 bit
 - parisc: parisc64 for 64 bit
-- sh: sh for 32 bit, sh64 for 64 bit
 - sparc: sparc32 for 32 bit, sparc64 for 64 bit
 
Quoted 4 lines

Documentation/kbuild/kbuild.rst But some architectures such as x86 and s · line 166

Quoted 1 line
Documentation/kbuild/kbuild.rst +0 -0
 CROSS_COMPILE

This hunk doesn't apply anymore since the parisc part has been dropped although I can't find the commit for that. Could you rebase your patch, please?

The parisc part has not been dropped. It's in linux-next but not yet in mainline. (commit 49deed336ef9a)

Do you want this patch to apply to mainline? (I created it in linux-next.) I can do that in a few hours. I'm busy ATM.

I suppose there will be a merge conflict between parisc and SH.

Quoted 1 line

Apologies that I didn't have the time earlier to start looking at this series!

No problem. We'll get there. Thanks.

Signature · 1 line
~Randy
#12 lore raw

Re: [PATCH 5/7 v4] sh: remove sh5/sh64 last fragments

Quoted 52 lines · Randy Dunlap

Hi--

Quoted 41 lines · John Paul Adrian Glaubitz

Hi Randy!

Quoted 38 lines · Randy Dunlap

A previous patch removed most of the sh5 (sh64) support from the kernel tree. Now remove the last stragglers.

Fixes 37744feebc08 ("sh: remove sh5 support")
Cc Geert Uytterhoeven <[email protected]>
Cc Arnd Bergmann <[email protected]>
Cc Rich Felker <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc John Paul Adrian Glaubitz <[email protected]>

---
v2: update after adding the parisc64 alias to kbuild.rst
v3: skipped
v4: refresh & resend

Documentation/kbuild/kbuild.rst                           |    1 -
Documentation/scheduler/sched-arch.rst                    |    2 --
Documentation/translations/zh_CN/scheduler/sched-arch.rst |    2 --
scripts/checkstack.pl                                     |    7 -------
tools/perf/arch/common.c                                  |    2 --
tools/scripts/Makefile.arch                               |    5 -----
tools/testing/selftests/mm/Makefile                       |    2 +-
tools/testing/selftests/mm/run_vmtests.sh                 |    2 +-
8 files changed, 2 insertions(+), 21 deletions(-)

diff -- a/Documentation/kbuild/kbuild.rst b/Documentation/kbuild/kbuild.rst

Documentation/kbuild/kbuild.rst +0 -4
@@ -161,7 +161,6 @@ But some architectures such as x86 and s
 
- x86: i386 for 32 bit, x86_64 for 64 bit
- parisc: parisc64 for 64 bit
-- sh: sh for 32 bit, sh64 for 64 bit
- sparc: sparc32 for 32 bit, sparc64 for 64 bit
 
Quoted 4 lines
Quoted 1 line

CROSS_COMPILE

This hunk doesn't apply anymore since the parisc part has been dropped although I can't find the commit for that. Could you rebase your patch, please?

Quoted 7 lines

The parisc part has not been dropped. It's in linux-next but not yet in mainline. (commit 49deed336ef9a)

Do you want this patch to apply to mainline? (I created it in linux-next.) I can do that in a few hours. I'm busy ATM.

I suppose there will be a merge conflict between parisc and SH.

Oops, sorry. My bad. I will use the proper tree.

Adrian

author reviewer
#13 lore raw

Re: [PATCH 5/7 v4] sh: remove sh5/sh64 last fragments

Quoted 55 lines · John Paul Adrian Glaubitz
Quoted 55 lines · Randy Dunlap

Hi--

Quoted 41 lines · John Paul Adrian Glaubitz

Hi Randy!

Quoted 38 lines · Randy Dunlap

A previous patch removed most of the sh5 (sh64) support from the kernel tree. Now remove the last stragglers.

Fixes 37744feebc08 ("sh: remove sh5 support")
Cc Geert Uytterhoeven <[email protected]>
Cc Arnd Bergmann <[email protected]>
Cc Rich Felker <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc John Paul Adrian Glaubitz <[email protected]>

---
v2: update after adding the parisc64 alias to kbuild.rst
v3: skipped
v4: refresh & resend

Documentation/kbuild/kbuild.rst                           |    1 -
Documentation/scheduler/sched-arch.rst                    |    2 --
Documentation/translations/zh_CN/scheduler/sched-arch.rst |    2 --
scripts/checkstack.pl                                     |    7 -------
tools/perf/arch/common.c                                  |    2 --
tools/scripts/Makefile.arch                               |    5 -----
tools/testing/selftests/mm/Makefile                       |    2 +-
tools/testing/selftests/mm/run_vmtests.sh                 |    2 +-
8 files changed, 2 insertions(+), 21 deletions(-)

diff -- a/Documentation/kbuild/kbuild.rst b/Documentation/kbuild/kbuild.rst

Documentation/kbuild/kbuild.rst +0 -4
@@ -161,7 +161,6 @@ But some architectures such as x86 and s
 
- x86: i386 for 32 bit, x86_64 for 64 bit
- parisc: parisc64 for 64 bit
-- sh: sh for 32 bit, sh64 for 64 bit
- sparc: sparc32 for 32 bit, sparc64 for 64 bit
 
Quoted 4 lines
Quoted 1 line

CROSS_COMPILE

This hunk doesn't apply anymore since the parisc part has been dropped although I can't find the commit for that. Could you rebase your patch, please?

The parisc part has not been dropped. It's in linux-next but not yet in mainline. (commit 49deed336ef9a)

Quoted 6 lines
Quoted 4 lines

Do you want this patch to apply to mainline? (I created it in linux-next.) I can do that in a few hours. I'm busy ATM.

I suppose there will be a merge conflict between parisc and SH.

Oops, sorry. My bad. I will use the proper tree.

Just let me know if you want me to resend it.
Thanks.

Signature · 1 line
~Randy
#14 lore raw

Re: [PATCH 5/7 v4] sh: remove sh5/sh64 last fragments

Hi Randy!

Quoted 4 lines · Randy Dunlap
Quoted 1 line

Oops, sorry. My bad. I will use the proper tree.

Just let me know if you want me to resend it.
Thanks.

No, that's fine. I will rebase my for-next tree.

Adrian

Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
#15 lore raw

Re: [PATCH 5/7 v4] sh: remove sh5/sh64 last fragments

Hi Adrian,

Quoted 7 lines · John Paul Adrian Glaubitz
Quoted 4 lines · Randy Dunlap
Quoted 1 line

Oops, sorry. My bad. I will use the proper tree.

Just let me know if you want me to resend it.
Thanks.

No, that's fine. I will rebase my for-next tree.

Rebase on top of what? Commit 49deed336ef9a409 ("parisc:
update kbuild doc. aliases for parisc64") is in the parisc tree. You must not base the SH tree on the parisc tree.

Don't care about the simple conflict, Stephen and Linus can handle that fine.

FTR, if the conflict was more complex, an immutable branch to be merged by all parties would be appropriate. But that's overkill and thus not needed for simple conflicts like this.

Gr{oetje,eeting}s,

Geert

Signature · 5 lines
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

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
#16 lore raw

Re: [PATCH 5/7 v4] sh: remove sh5/sh64 last fragments

Hi Geert!

Quoted 7 lines · Geert Uytterhoeven

Hi Adrian,

Quoted 3 lines · John Paul Adrian Glaubitz
Quoted 2 lines · Randy Dunlap
Quoted 1 line

Oops, sorry. My bad. I will use the proper tree.

Quoted 8 lines
Quoted 4 lines
Quoted 2 lines

Just let me know if you want me to resend it.
Thanks.

No, that's fine. I will rebase my for-next tree.

Rebase on top of what? Commit 49deed336ef9a409 ("parisc:
update kbuild doc. aliases for parisc64") is in the parisc tree. You must not base the SH tree on the parisc tree.

Oh, I wasn't aware of that.

Quoted 6 lines

Don't care about the simple conflict, Stephen and Linus can handle that fine.

FTR, if the conflict was more complex, an immutable branch to be merged by all parties would be appropriate. But that's overkill and thus not needed for simple conflicts like this.

I'll resolve the conflict manually then. Thanks.

Adrian

Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
maintainer Reviewed-by on v4 5/7
#17 lore raw

Re: [PATCH 5/7 v4] sh: remove sh5/sh64 last fragments

In reply to Randy Dunlap
Quoted 128 lines · Randy Dunlap

A previous patch removed most of the sh5 (sh64) support from the kernel tree. Now remove the last stragglers.

Fixes 37744feebc08 ("sh: remove sh5 support")
Cc Geert Uytterhoeven <[email protected]>
Cc Arnd Bergmann <[email protected]>
Cc Rich Felker <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc John Paul Adrian Glaubitz <[email protected]>

---
v2: update after adding the parisc64 alias to kbuild.rst
v3: skipped
v4: refresh & resend

 Documentation/kbuild/kbuild.rst                           |    1 -
 Documentation/scheduler/sched-arch.rst                    |    2 --
 Documentation/translations/zh_CN/scheduler/sched-arch.rst |    2 --
 scripts/checkstack.pl                                     |    7 -------
 tools/perf/arch/common.c                                  |    2 --
 tools/scripts/Makefile.arch                               |    5 -----
 tools/testing/selftests/mm/Makefile                       |    2 +-
 tools/testing/selftests/mm/run_vmtests.sh                 |    2 +-
 8 files changed, 2 insertions(+), 21 deletions(-)

diff -- a/Documentation/kbuild/kbuild.rst b/Documentation/kbuild/kbuild.rst

Documentation/kbuild/kbuild.rst +0 -1
@@ -161,7 +161,6 @@ But some architectures such as x86 and s
 
 - x86: i386 for 32 bit, x86_64 for 64 bit
 - parisc: parisc64 for 64 bit
-- sh: sh for 32 bit, sh64 for 64 bit
 - sparc: sparc32 for 32 bit, sparc64 for 64 bit
 
 CROSS_COMPILE

diff -- a/Documentation/scheduler/sched-arch.rst b/Documentation/scheduler/sched-arch.rst

Documentation/scheduler/sched-arch.rst +0 -2
@@ -70,7 +70,5 @@ Possible arch problems I found (and eith
 
 ia64 - is safe_halt call racy vs interrupts? (does it sleep?) (See #4a)
 
-sh64 - Is sleeping racy vs interrupts? (See #4a)
-
 sparc - IRQs on at this point(?), change local_irq_save to _disable.
       - TODO: needs secondary CPUs to disable preempt (See #1)

diff -- a/Documentation/translations/zh_CN/scheduler/sched-arch.rst b/Documentation/translations/zh_CN/scheduler/sched-arch.rst

Documentation/translations/zh_CN/scheduler/sched-arch.rst +0 -2
@@ -70,7 +70,5 @@ 我发现的可能的arch问题(并试
 
 ia64 - safe_halt的调用与中断相比,是否很荒谬? (它睡眠了吗) (参考 #4a)
 
-sh64 - 睡眠与中断相比,是否很荒谬? (参考 #4a)
-
 sparc - 在这一点上,IRQ是开着的(?),把local_irq_save改为_disable。
       - 待办事项: 需要第二个CPU来禁用抢占 (参考 #1)

diff -- a/scripts/checkstack.pl b/scripts/checkstack.pl

scripts/checkstack.pl +0 -7
@@ -10,7 +10,6 @@
 #	Mips port by Juan Quintela <[email protected]>
 #	IA64 port via Andreas Dilger
 #	Arm port by Holger Schurig
-#	sh64 port by Paul Mundt
 #	Random bits by Matt Mackall <[email protected]>
 #	M68k port by Geert Uytterhoeven and Andreas Schwab
 #	AArch64, PARISC ports by Kyle McMartin
@@ -100,12 +99,6 @@ my (@stack, $re, $dre, $sub, $x, $xs, $f
 		#  100092:	 e3 f0 ff c8 ff 71	 lay	 %r15,-56(%r15)
 		$re = qr/.*(?:lay|ag?hi).*\%r15,-(([0-9]{2}|[3-9])[0-9]{2})
 		      (?:\(\%r15\))?$/ox;
-	} elsif ($arch =~ /^sh64$/) {
-		#XXX: we only check for the immediate case presently,
-		#     though we will want to check for the movi/sub
-		#     pair for larger users. -- PFM.
-		#a00048e0:       d4fc40f0        addi.l  r15,-240,r15
-		$re = qr/.*addi\.l.*r15,-(([0-9]{2}|[3-9])[0-9]{2}),r15/o;
 	} elsif ($arch eq 'sparc' || $arch eq 'sparc64') {
 		# f0019d10:       9d e3 bf 90     save  %sp, -112, %sp
 		$re = qr/.*save.*%sp, -(([0-9]{2}|[3-9])[0-9]{2}), %sp/o;

diff -- a/tools/perf/arch/common.c b/tools/perf/arch/common.c

tools/perf/arch/common.c +0 -2
@@ -51,9 +51,7 @@ const char *const s390_triplets[] = {
 
 const char *const sh_triplets[] = {
 	"sh-unknown-linux-gnu-",
-	"sh64-unknown-linux-gnu-",
 	"sh-linux-gnu-",
-	"sh64-linux-gnu-",
 	NULL
 };
 

diff -- a/tools/scripts/Makefile.arch b/tools/scripts/Makefile.arch

tools/scripts/Makefile.arch +0 -5
@@ -29,11 +29,6 @@ ifeq ($(ARCH),sparc64)
        SRCARCH := sparc
 endif
 
-# Additional ARCH settings for sh
-ifeq ($(ARCH),sh64)
-       SRCARCH := sh
-endif
-
 # Additional ARCH settings for loongarch
 ifeq ($(ARCH),loongarch32)
        SRCARCH := loongarch

diff -- a/tools/testing/selftests/mm/Makefile b/tools/testing/selftests/mm/Makefile

tools/testing/selftests/mm/Makefile +1 -1
@@ -90,7 +90,7 @@ endif
 
 endif
 
-ifneq (,$(filter $(MACHINE),arm64 ia64 mips64 parisc64 ppc64 riscv64 s390x sh64 sparc64 x86_64))
+ifneq (,$(filter $(MACHINE),arm64 ia64 mips64 parisc64 ppc64 riscv64 s390x sparc64 x86_64))
 TEST_GEN_FILES += va_128TBswitch
 TEST_GEN_FILES += virtual_address_range
 TEST_GEN_FILES += write_to_hugetlbfs

diff -- a/tools/testing/selftests/mm/run_vmtests.sh b/tools/testing/selftests/mm/run_vmtests.sh

tools/testing/selftests/mm/run_vmtests.sh else · line 138

Quoted 8 lines
tools/testing/selftests/mm/run_vmtests.sh +1 -1
@@ -132,7 +132,7 @@ else
 fi
 
 # filter 64bit architectures
-ARCH64STR="arm64 ia64 mips64 parisc64 ppc64 ppc64le riscv64 s390x sh64 sparc64 x86_64"
+ARCH64STR="arm64 ia64 mips64 parisc64 ppc64 ppc64le riscv64 s390x sparc64 x86_64"
 if [ -z "$ARCH" ]; then
 	ARCH=$(uname -m 2>/dev/null | sed -e 's/aarch64.*/arm64/')
 fi
Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
author reviewer
#18 lore raw

PATCH v4 6/7 sh: fix Kconfig entry for NUMA => SMP

In reply to Randy Dunlap

Fix SUPERH builds that select SYS_SUPPORTS_NUMA but do not select SYS_SUPPORTS_SMP and SMP.

kernel/sched/topology.c is only built for CONFIG_SMP and then the NUMA code + data inside topology.c is only built when CONFIG_NUMA is set/enabled, so these arch/sh/ configs need to select SMP and SYS_SUPPORTS_SMP to build the NUMA support.

Fixes this build error in multiple SUPERH configs:

mm/page_alloc.o: In function `get_page_from_freelist':
page_alloc.c:(.text+0x2ca8): undefined reference to `node_reclaim_distance'

Fixes 357d59469c11 ("sh: Tidy up dependencies for SH-2 build.")
Fixes 9109a30e5a54 ("sh: add support for sh7366 processor")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: skipped
v3: skipped
v4: refresh & resend

 arch/sh/Kconfig |    4 ++++
 1 file changed, 4 insertions(+)
arch/sh/Kconfig +4 -0
diff -- a/arch/sh/Kconfig b/arch/sh/Kconfig
@@ -477,6 +477,8 @@ config CPU_SUBTYPE_SH7722
 	select CPU_SHX2
 	select ARCH_SHMOBILE
 	select ARCH_SPARSEMEM_ENABLE
+	select SYS_SUPPORTS_SMP
+	select SMP
 	select SYS_SUPPORTS_NUMA
 	select SYS_SUPPORTS_SH_CMT
 	select PINCTRL
@@ -487,6 +489,8 @@ config CPU_SUBTYPE_SH7366
 	select CPU_SHX2
 	select ARCH_SHMOBILE
 	select ARCH_SPARSEMEM_ENABLE
+	select SYS_SUPPORTS_SMP
+	select SMP
 	select SYS_SUPPORTS_NUMA
 	select SYS_SUPPORTS_SH_CMT
 
#19 lore raw

Re: [PATCH 6/7 v4] sh: fix Kconfig entry for NUMA => SMP

Quoted 43 lines · Randy Dunlap

Fix SUPERH builds that select SYS_SUPPORTS_NUMA but do not select SYS_SUPPORTS_SMP and SMP.

kernel/sched/topology.c is only built for CONFIG_SMP and then the NUMA code + data inside topology.c is only built when CONFIG_NUMA is set/enabled, so these arch/sh/ configs need to select SMP and SYS_SUPPORTS_SMP to build the NUMA support.

Fixes this build error in multiple SUPERH configs:

mm/page_alloc.o: In function `get_page_from_freelist':
page_alloc.c:(.text+0x2ca8): undefined reference to `node_reclaim_distance'

Fixes 357d59469c11 ("sh: Tidy up dependencies for SH-2 build.")
Fixes 9109a30e5a54 ("sh: add support for sh7366 processor")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: skipped
v3: skipped
v4: refresh & resend

 arch/sh/Kconfig |    4 ++++
 1 file changed, 4 insertions(+)

diff -- a/arch/sh/Kconfig b/arch/sh/Kconfig

arch/sh/Kconfig +2 -0
@@ -477,6 +477,8 @@ config CPU_SUBTYPE_SH7722
 	select CPU_SHX2
 	select ARCH_SHMOBILE
 	select ARCH_SPARSEMEM_ENABLE
+	select SYS_SUPPORTS_SMP
+	select SMP
 	select SYS_SUPPORTS_NUMA
 	select SYS_SUPPORTS_SH_CMT
 	select PINCTRL

arch/sh/Kconfig config CPU_SUBTYPE_SH7366 · line 496

Quoted 8 lines
arch/sh/Kconfig +2 -0
@@ -487,6 +489,8 @@ config CPU_SUBTYPE_SH7366
 	select CPU_SHX2
 	select ARCH_SHMOBILE
 	select ARCH_SPARSEMEM_ENABLE
+	select SYS_SUPPORTS_SMP
+	select SMP
 	select SYS_SUPPORTS_NUMA
 	select SYS_SUPPORTS_SH_CMT
 

It seems that we need this change for these configurations as well:

- config CPU_SHX3
- config CPU_SUBTYPE_SH7785

Although I can trigger a build failure for CPU_SUBTYPE_SH7785 only when setting CONFIG_NUMA=y:

CC net/ipv6/addrconf_core.o
mm/slab.c: In function 'slab_memory_callback':
mm/slab.c:1127:23: error: implicit declaration of function 'init_cache_node_node'; did you mean 'drain_cache_node_node'? [-Werror=implicit-function-declaration]

 1127 |                 ret = init_cache_node_node(nid);
      |                       ^~~~~~~~~~~~~~~~~~~~
      |                       drain_cache_node_node

I would expect this error to be reproducible for CPU_SHX3 as well when CONFIG_NUMA=y but CONFIG_SMP=n. But for some reason, I am not seeing the error then.

Adrian

Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
#20 lore raw

Re: [PATCH 6/7 v4] sh: fix Kconfig entry for NUMA => SMP

Hi Randy!

Quoted 64 lines · John Paul Adrian Glaubitz
Quoted 43 lines · Randy Dunlap

Fix SUPERH builds that select SYS_SUPPORTS_NUMA but do not select SYS_SUPPORTS_SMP and SMP.

kernel/sched/topology.c is only built for CONFIG_SMP and then the NUMA code + data inside topology.c is only built when CONFIG_NUMA is set/enabled, so these arch/sh/ configs need to select SMP and SYS_SUPPORTS_SMP to build the NUMA support.

Fixes this build error in multiple SUPERH configs:

mm/page_alloc.o: In function `get_page_from_freelist':
page_alloc.c:(.text+0x2ca8): undefined reference to `node_reclaim_distance'

Fixes 357d59469c11 ("sh: Tidy up dependencies for SH-2 build.")
Fixes 9109a30e5a54 ("sh: add support for sh7366 processor")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: skipped
v3: skipped
v4: refresh & resend

 arch/sh/Kconfig |    4 ++++
 1 file changed, 4 insertions(+)

diff -- a/arch/sh/Kconfig b/arch/sh/Kconfig

arch/sh/Kconfig +2 -0
@@ -477,6 +477,8 @@ config CPU_SUBTYPE_SH7722
 	select CPU_SHX2
 	select ARCH_SHMOBILE
 	select ARCH_SPARSEMEM_ENABLE
+	select SYS_SUPPORTS_SMP
+	select SMP
 	select SYS_SUPPORTS_NUMA
 	select SYS_SUPPORTS_SH_CMT
 	select PINCTRL

arch/sh/Kconfig config CPU_SUBTYPE_SH7366 · line 496

Quoted 8 lines
arch/sh/Kconfig +2 -0
@@ -487,6 +489,8 @@ config CPU_SUBTYPE_SH7366
 	select CPU_SHX2
 	select ARCH_SHMOBILE
 	select ARCH_SPARSEMEM_ENABLE
+	select SYS_SUPPORTS_SMP
+	select SMP
 	select SYS_SUPPORTS_NUMA
 	select SYS_SUPPORTS_SH_CMT
 

It seems that we need this change for these configurations as well:

- config CPU_SHX3
- config CPU_SUBTYPE_SH7785

Although I can trigger a build failure for CPU_SUBTYPE_SH7785 only when setting CONFIG_NUMA=y:

CC net/ipv6/addrconf_core.o
mm/slab.c: In function 'slab_memory_callback':
mm/slab.c:1127:23: error: implicit declaration of function 'init_cache_node_node'; did you mean 'drain_cache_node_node'? [-Werror=implicit-function-declaration]

Quoted 7 lines
 1127 |                 ret = init_cache_node_node(nid);
      |                       ^~~~~~~~~~~~~~~~~~~~
      |                       drain_cache_node_node

I would expect this error to be reproducible for CPU_SHX3 as well when CONFIG_NUMA=y but CONFIG_SMP=n. But for some reason, I am not seeing the error then.

Can you make this change for config CPU_SUBTYPE_SH7785 as well?

Then the change should be fine.

Adrian

Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
author reviewer
#21 lore raw

Re: [PATCH 6/7 v4] sh: fix Kconfig entry for NUMA => SMP

Quoted 71 lines · John Paul Adrian Glaubitz

Hi Randy!

Quoted 68 lines · John Paul Adrian Glaubitz
Quoted 43 lines · Randy Dunlap

Fix SUPERH builds that select SYS_SUPPORTS_NUMA but do not select SYS_SUPPORTS_SMP and SMP.

kernel/sched/topology.c is only built for CONFIG_SMP and then the NUMA code + data inside topology.c is only built when CONFIG_NUMA is set/enabled, so these arch/sh/ configs need to select SMP and SYS_SUPPORTS_SMP to build the NUMA support.

Fixes this build error in multiple SUPERH configs:

mm/page_alloc.o: In function `get_page_from_freelist':
page_alloc.c:(.text+0x2ca8): undefined reference to `node_reclaim_distance'

Fixes 357d59469c11 ("sh: Tidy up dependencies for SH-2 build.")
Fixes 9109a30e5a54 ("sh: add support for sh7366 processor")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: skipped
v3: skipped
v4: refresh & resend

 arch/sh/Kconfig |    4 ++++
 1 file changed, 4 insertions(+)

diff -- a/arch/sh/Kconfig b/arch/sh/Kconfig

arch/sh/Kconfig +2 -0
@@ -477,6 +477,8 @@ config CPU_SUBTYPE_SH7722
 	select CPU_SHX2
 	select ARCH_SHMOBILE
 	select ARCH_SPARSEMEM_ENABLE
+	select SYS_SUPPORTS_SMP
+	select SMP
 	select SYS_SUPPORTS_NUMA
 	select SYS_SUPPORTS_SH_CMT
 	select PINCTRL

arch/sh/Kconfig config CPU_SUBTYPE_SH7366 · line 496

Quoted 8 lines
arch/sh/Kconfig +2 -0
@@ -487,6 +489,8 @@ config CPU_SUBTYPE_SH7366
 	select CPU_SHX2
 	select ARCH_SHMOBILE
 	select ARCH_SPARSEMEM_ENABLE
+	select SYS_SUPPORTS_SMP
+	select SMP
 	select SYS_SUPPORTS_NUMA
 	select SYS_SUPPORTS_SH_CMT
 

It seems that we need this change for these configurations as well:

- config CPU_SHX3
- config CPU_SUBTYPE_SH7785

Although I can trigger a build failure for CPU_SUBTYPE_SH7785 only when setting CONFIG_NUMA=y:

CC net/ipv6/addrconf_core.o
mm/slab.c: In function 'slab_memory_callback':
mm/slab.c:1127:23: error: implicit declaration of function 'init_cache_node_node'; did you mean 'drain_cache_node_node'? [-Werror=implicit-function-declaration]

 1127 |                 ret = init_cache_node_node(nid);
      |                       ^~~~~~~~~~~~~~~~~~~~
      |                       drain_cache_node_node
Quoted 7 lines
Quoted 3 lines

I would expect this error to be reproducible for CPU_SHX3 as well when CONFIG_NUMA=y but CONFIG_SMP=n. But for some reason, I am not seeing the error then.

Can you make this change for config CPU_SUBTYPE_SH7785 as well?

Then the change should be fine.

Will do. Thanks.

Signature · 1 line
~Randy
author reviewer
#22 lore raw

PATCH v4 7/7 sh: mcount.S: fix build error when PRINTK is not enabled

In reply to Randy Dunlap

Fix a build error in mcount.S when CONFIG_PRINTK is not enabled. Fixes this build error:

sh2-linux-ld: arch/sh/lib/mcount.o: in function `stack_panic':
(.text+0xec): undefined reference to `dump_stack'

Fixes e460ab27b6c3 ("sh: Fix up stack overflow check with ftrace disabled.")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: add PRINTK to STACK_DEBUG dependency (thanks, Geert)
v3: skipped
v4: refresh & resend

 arch/sh/Kconfig.debug |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/sh/Kconfig.debug +1 -1
diff -- a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug
@@ -15,7 +15,7 @@ config SH_STANDARD_BIOS
 
 config STACK_DEBUG
 	bool "Check for stack overflows"
-	depends on DEBUG_KERNEL
+	depends on DEBUG_KERNEL && PRINTK
 	help
 	  This option will cause messages to be printed if free stack space
 	  drops below a certain limit. Saying Y here will add overhead to
#23 lore raw

Re: [PATCH 7/7 v4] sh: mcount.S: fix build error when PRINTK is not enabled

Quoted 25 lines · Randy Dunlap

Fix a build error in mcount.S when CONFIG_PRINTK is not enabled. Fixes this build error:

sh2-linux-ld: arch/sh/lib/mcount.o: in function `stack_panic':
(.text+0xec): undefined reference to `dump_stack'

Fixes e460ab27b6c3 ("sh: Fix up stack overflow check with ftrace disabled.")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: add PRINTK to STACK_DEBUG dependency (thanks, Geert)
v3: skipped
v4: refresh & resend

 arch/sh/Kconfig.debug |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -- a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug

arch/sh/Kconfig.debug config SH_STANDARD_BIOS · line 21

Quoted 8 lines
arch/sh/Kconfig.debug +1 -1
@@ -15,7 +15,7 @@ config SH_STANDARD_BIOS
 
 config STACK_DEBUG
 	bool "Check for stack overflows"
-	depends on DEBUG_KERNEL
+	depends on DEBUG_KERNEL && PRINTK
 	help
 	  This option will cause messages to be printed if free stack space
 	  drops below a certain limit. Saying Y here will add overhead to

I can't really test this change as the moment I am enabling CONFIG_STACK_DEBUG, the build fails with:

CC scripts/mod/devicetable-offsets.s
sh4-linux-gcc: error: -pg and -fomit-frame-pointer are incompatible make[1]: *** [scripts/Makefile.build:252: scripts/mod/empty.o] Error 1 make[1]: *** Waiting for unfinished jobs....
sh4-linux-gcc: error: -pg and -fomit-frame-pointer are incompatible make[1]: *** [scripts/Makefile.build:114: scripts/mod/devicetable-offsets.s] Error 1
make: *** [Makefile:1286: prepare0] Error 2

So, I assume we need to strip -fomit-frame-pointer from KBUILD_CFLAGS, correct?

I tried this change, but that doesn't fix it for me:

arch/sh/Makefile +1 -0
index 5c8776482530..83f535b73835 100644
@@ -173,6 +173,7 @@ KBUILD_AFLAGS               += $(cflags-y)
 
 ifeq ($(CONFIG_MCOUNT),y)
   KBUILD_CFLAGS += -pg
+  KBUILD_CFLAGS := $(subst -fomit-frame-pointer,,$(KBUILD_CFLAGS))
 endif
 
 ifeq ($(CONFIG_DWARF_UNWINDER),y)

Any ideas?

Adrian

Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
#24 lore raw

Re: [PATCH 7/7 v4] sh: mcount.S: fix build error when PRINTK is not enabled

Hi Adrian,

Quoted 63 lines · John Paul Adrian Glaubitz
Quoted 25 lines · Randy Dunlap

Fix a build error in mcount.S when CONFIG_PRINTK is not enabled. Fixes this build error:

sh2-linux-ld: arch/sh/lib/mcount.o: in function `stack_panic':
(.text+0xec): undefined reference to `dump_stack'

Fixes e460ab27b6c3 ("sh: Fix up stack overflow check with ftrace disabled.")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: add PRINTK to STACK_DEBUG dependency (thanks, Geert)
v3: skipped
v4: refresh & resend

 arch/sh/Kconfig.debug |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -- a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug

arch/sh/Kconfig.debug config SH_STANDARD_BIOS · line 21

Quoted 8 lines
arch/sh/Kconfig.debug +1 -1
@@ -15,7 +15,7 @@ config SH_STANDARD_BIOS
 
 config STACK_DEBUG
      bool "Check for stack overflows"
-     depends on DEBUG_KERNEL
+     depends on DEBUG_KERNEL && PRINTK
      help
        This option will cause messages to be printed if free stack space
        drops below a certain limit. Saying Y here will add overhead to

I can't really test this change as the moment I am enabling CONFIG_STACK_DEBUG, the build fails with:

CC scripts/mod/devicetable-offsets.s
sh4-linux-gcc: error: -pg and -fomit-frame-pointer are incompatible make[1]: *** [scripts/Makefile.build:252: scripts/mod/empty.o] Error 1 make[1]: *** Waiting for unfinished jobs....
sh4-linux-gcc: error: -pg and -fomit-frame-pointer are incompatible make[1]: *** [scripts/Makefile.build:114: scripts/mod/devicetable-offsets.s] Error 1
make: *** [Makefile:1286: prepare0] Error 2

So, I assume we need to strip -fomit-frame-pointer from KBUILD_CFLAGS, correct?

I tried this change, but that doesn't fix it for me:

arch/sh/Makefile +1 -0
index 5c8776482530..83f535b73835 100644
@@ -173,6 +173,7 @@ KBUILD_AFLAGS               += $(cflags-y)
 
 ifeq ($(CONFIG_MCOUNT),y)
   KBUILD_CFLAGS += -pg
+  KBUILD_CFLAGS := $(subst -fomit-frame-pointer,,$(KBUILD_CFLAGS))
 endif
 
 ifeq ($(CONFIG_DWARF_UNWINDER),y)
Quoted 1 line

Any ideas?

Please try with "+=" instead of ":=".

Gr{oetje,eeting}s,

Geert

Signature · 5 lines
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

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
#25 lore raw

Re: [PATCH 7/7 v4] sh: mcount.S: fix build error when PRINTK is not enabled

Hi Geert!

Quoted 65 lines · Geert Uytterhoeven

Hi Adrian,

Quoted 61 lines · John Paul Adrian Glaubitz
Quoted 25 lines · Randy Dunlap

Fix a build error in mcount.S when CONFIG_PRINTK is not enabled. Fixes this build error:

sh2-linux-ld: arch/sh/lib/mcount.o: in function `stack_panic':
(.text+0xec): undefined reference to `dump_stack'

Fixes e460ab27b6c3 ("sh: Fix up stack overflow check with ftrace disabled.")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: add PRINTK to STACK_DEBUG dependency (thanks, Geert)
v3: skipped
v4: refresh & resend

 arch/sh/Kconfig.debug |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -- a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug

arch/sh/Kconfig.debug config SH_STANDARD_BIOS · line 21

Quoted 8 lines
arch/sh/Kconfig.debug +1 -1
@@ -15,7 +15,7 @@ config SH_STANDARD_BIOS
 
 config STACK_DEBUG
      bool "Check for stack overflows"
-     depends on DEBUG_KERNEL
+     depends on DEBUG_KERNEL && PRINTK
      help
        This option will cause messages to be printed if free stack space
        drops below a certain limit. Saying Y here will add overhead to

I can't really test this change as the moment I am enabling CONFIG_STACK_DEBUG, the build fails with:

CC scripts/mod/devicetable-offsets.s
sh4-linux-gcc: error: -pg and -fomit-frame-pointer are incompatible make[1]: *** [scripts/Makefile.build:252: scripts/mod/empty.o] Error 1 make[1]: *** Waiting for unfinished jobs....
sh4-linux-gcc: error: -pg and -fomit-frame-pointer are incompatible make[1]: *** [scripts/Makefile.build:114: scripts/mod/devicetable-offsets.s] Error 1
make: *** [Makefile:1286: prepare0] Error 2

So, I assume we need to strip -fomit-frame-pointer from KBUILD_CFLAGS, correct?

I tried this change, but that doesn't fix it for me:

arch/sh/Makefile +1 -0
index 5c8776482530..83f535b73835 100644
@@ -173,6 +173,7 @@ KBUILD_AFLAGS               += $(cflags-y)
 
 ifeq ($(CONFIG_MCOUNT),y)
   KBUILD_CFLAGS += -pg
+  KBUILD_CFLAGS := $(subst -fomit-frame-pointer,,$(KBUILD_CFLAGS))
 endif
 
Quoted 5 lines
Quoted 3 lines
arch/sh/Makefile +0 -0
 ifeq ($(CONFIG_DWARF_UNWINDER),y)

Any ideas?

Please try with "+=" instead of ":=".

That doesn't work either. I tried the following, but that didn't strip -fomit-frame-pointer:

arch/sh/Makefile +1 -1
index 5c8776482530..9eef6f6ffc8b 100644
@@ -172,7 +172,7 @@ KBUILD_CPPFLAGS             += $(cflags-y)
 KBUILD_AFLAGS          += $(cflags-y)
 
 ifeq ($(CONFIG_MCOUNT),y)
-  KBUILD_CFLAGS += -pg
+  KBUILD_CFLAGS := $(subst -fomit-frame-pointer,,$(KBUILD_CFLAGS)) -pg
 endif
 
 ifeq ($(CONFIG_DWARF_UNWINDER),y)

I will have to do some more digging tonight.

Adrian

Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
#26 lore raw

Re: [PATCH 7/7 v4] sh: mcount.S: fix build error when PRINTK is not enabled

Hi Adrian,

Quoted 64 lines · John Paul Adrian Glaubitz
Quoted 63 lines · Geert Uytterhoeven
Quoted 61 lines · John Paul Adrian Glaubitz
Quoted 25 lines · Randy Dunlap

Fix a build error in mcount.S when CONFIG_PRINTK is not enabled. Fixes this build error:

sh2-linux-ld: arch/sh/lib/mcount.o: in function `stack_panic':
(.text+0xec): undefined reference to `dump_stack'

Fixes e460ab27b6c3 ("sh: Fix up stack overflow check with ftrace disabled.")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: add PRINTK to STACK_DEBUG dependency (thanks, Geert)
v3: skipped
v4: refresh & resend

 arch/sh/Kconfig.debug |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -- a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug

arch/sh/Kconfig.debug config SH_STANDARD_BIOS · line 21

Quoted 8 lines
arch/sh/Kconfig.debug +1 -1
@@ -15,7 +15,7 @@ config SH_STANDARD_BIOS
 
 config STACK_DEBUG
      bool "Check for stack overflows"
-     depends on DEBUG_KERNEL
+     depends on DEBUG_KERNEL && PRINTK
      help
        This option will cause messages to be printed if free stack space
        drops below a certain limit. Saying Y here will add overhead to

I can't really test this change as the moment I am enabling CONFIG_STACK_DEBUG, the build fails with:

CC scripts/mod/devicetable-offsets.s
sh4-linux-gcc: error: -pg and -fomit-frame-pointer are incompatible make[1]: *** [scripts/Makefile.build:252: scripts/mod/empty.o] Error 1 make[1]: *** Waiting for unfinished jobs....
sh4-linux-gcc: error: -pg and -fomit-frame-pointer are incompatible make[1]: *** [scripts/Makefile.build:114: scripts/mod/devicetable-offsets.s] Error 1
make: *** [Makefile:1286: prepare0] Error 2

So, I assume we need to strip -fomit-frame-pointer from KBUILD_CFLAGS, correct?

I tried this change, but that doesn't fix it for me:

arch/sh/Makefile +1 -0
index 5c8776482530..83f535b73835 100644
@@ -173,6 +173,7 @@ KBUILD_AFLAGS               += $(cflags-y)
 
 ifeq ($(CONFIG_MCOUNT),y)
   KBUILD_CFLAGS += -pg
+  KBUILD_CFLAGS := $(subst -fomit-frame-pointer,,$(KBUILD_CFLAGS))
 endif
 
Quoted 7 lines
Quoted 5 lines
Quoted 3 lines
arch/sh/Makefile +0 -0
 ifeq ($(CONFIG_DWARF_UNWINDER),y)

Any ideas?

Please try with "+=" instead of ":=".

That doesn't work either. I tried the following, but that didn't strip -fomit-frame-pointer:

Oops, obviously all of that happened before my morning coffee ;-)

Makefile has:

ifdef CONFIG_FRAME_POINTER
KBUILD_CFLAGS += -fno-omit-frame-pointer -fno-optimize-sibling-calls
KBUILD_RUSTFLAGS += -Cforce-frame-pointers=y
else
# Some targets (ARM with Thumb2, for example), can't be built with frame # pointers. For those, we don't have FUNCTION_TRACER automatically # select FRAME_POINTER. However, FUNCTION_TRACER adds -pg, and this is # incompatible with -fomit-frame-pointer with current GCC, so we don't use # -fomit-frame-pointer with FUNCTION_TRACER.
# In the Rust target specification, "frame-pointer" is set explicitly # to "may-omit".
ifndef CONFIG_FUNCTION_TRACER
KBUILD_CFLAGS += -fomit-frame-pointer
endif
endif

Your config probably has CONFIG_FRAME_POINTER set?

arch/sh/Kconfig.debug=config DWARF_UNWINDER arch/sh/Kconfig.debug- bool "Enable the DWARF unwinder for stacktraces" arch/sh/Kconfig.debug- depends on DEBUG_KERNEL arch/sh/Kconfig.debug: select FRAME_POINTER

You should make sure that cannot happen when CONFIG_FUNCTION_TRACER is enabled. I.e. make DWARF_UNWINDER depend on !FUNCTION_TRACER?

Other architectures do something similar:

arch/sparc/Kconfig.debug:config FRAME_POINTER
arch/sparc/Kconfig.debug- bool
arch/sparc/Kconfig.debug- depends on MCOUNT

arch/x86/Kconfig.debug:config FRAME_POINTER arch/x86/Kconfig.debug- depends on !UNWINDER_ORC && !UNWINDER_GUESS arch/x86/Kconfig.debug- bool

Probably you need to adjust the following, too:

lib/Kconfig.debug:config FRAME_POINTER
lib/Kconfig.debug- bool "Compile the kernel with frame pointers"
lib/Kconfig.debug- depends on DEBUG_KERNEL && (M68K || UML ||
SUPERH) || ARCH_WANT_FRAME_POINTERS

    lib/Kconfig.debug-      default y if (DEBUG_INFO && UML) ||

ARCH_WANT_FRAME_POINTERS

i.e. drop SUPERH from the list above, and select ARCH_WANT_FRAME_POINTERS if !FUNCTION_TRACER.

Gr{oetje,eeting}s,

Geert

Signature · 5 lines
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

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
#27 lore raw

Re: [PATCH 7/7 v4] sh: mcount.S: fix build error when PRINTK is not enabled

CC linux-sh

Quoted 136 lines · Geert Uytterhoeven
Quoted 64 lines · John Paul Adrian Glaubitz
Quoted 63 lines · Geert Uytterhoeven
Quoted 61 lines · John Paul Adrian Glaubitz
Quoted 25 lines · Randy Dunlap

Fix a build error in mcount.S when CONFIG_PRINTK is not enabled. Fixes this build error:

sh2-linux-ld: arch/sh/lib/mcount.o: in function `stack_panic':
(.text+0xec): undefined reference to `dump_stack'

Fixes e460ab27b6c3 ("sh: Fix up stack overflow check with ftrace disabled.")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: add PRINTK to STACK_DEBUG dependency (thanks, Geert)
v3: skipped
v4: refresh & resend

 arch/sh/Kconfig.debug |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -- a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug

arch/sh/Kconfig.debug config SH_STANDARD_BIOS · line 21

Quoted 8 lines
arch/sh/Kconfig.debug +1 -1
@@ -15,7 +15,7 @@ config SH_STANDARD_BIOS
 
 config STACK_DEBUG
      bool "Check for stack overflows"
-     depends on DEBUG_KERNEL
+     depends on DEBUG_KERNEL && PRINTK
      help
        This option will cause messages to be printed if free stack space
        drops below a certain limit. Saying Y here will add overhead to

I can't really test this change as the moment I am enabling CONFIG_STACK_DEBUG, the build fails with:

CC scripts/mod/devicetable-offsets.s
sh4-linux-gcc: error: -pg and -fomit-frame-pointer are incompatible make[1]: *** [scripts/Makefile.build:252: scripts/mod/empty.o] Error 1 make[1]: *** Waiting for unfinished jobs....
sh4-linux-gcc: error: -pg and -fomit-frame-pointer are incompatible make[1]: *** [scripts/Makefile.build:114: scripts/mod/devicetable-offsets.s] Error 1
make: *** [Makefile:1286: prepare0] Error 2

So, I assume we need to strip -fomit-frame-pointer from KBUILD_CFLAGS, correct?

I tried this change, but that doesn't fix it for me:

arch/sh/Makefile +1 -0
index 5c8776482530..83f535b73835 100644
@@ -173,6 +173,7 @@ KBUILD_AFLAGS               += $(cflags-y)
 
 ifeq ($(CONFIG_MCOUNT),y)
   KBUILD_CFLAGS += -pg
+  KBUILD_CFLAGS := $(subst -fomit-frame-pointer,,$(KBUILD_CFLAGS))
 endif
 
Quoted 7 lines
Quoted 5 lines
Quoted 3 lines
arch/sh/Makefile +0 -0
 ifeq ($(CONFIG_DWARF_UNWINDER),y)

Any ideas?

Please try with "+=" instead of ":=".

That doesn't work either. I tried the following, but that didn't strip -fomit-frame-pointer:

Oops, obviously all of that happened before my morning coffee ;-)

Makefile has:

ifdef CONFIG_FRAME_POINTER
KBUILD_CFLAGS += -fno-omit-frame-pointer -fno-optimize-sibling-calls
KBUILD_RUSTFLAGS += -Cforce-frame-pointers=y
else
# Some targets (ARM with Thumb2, for example), can't be built with frame # pointers. For those, we don't have FUNCTION_TRACER automatically # select FRAME_POINTER. However, FUNCTION_TRACER adds -pg, and this is # incompatible with -fomit-frame-pointer with current GCC, so we don't use # -fomit-frame-pointer with FUNCTION_TRACER.
# In the Rust target specification, "frame-pointer" is set explicitly # to "may-omit".
ifndef CONFIG_FUNCTION_TRACER
KBUILD_CFLAGS += -fomit-frame-pointer
endif
endif

Your config probably has CONFIG_FRAME_POINTER set?

arch/sh/Kconfig.debug=config DWARF_UNWINDER arch/sh/Kconfig.debug- bool "Enable the DWARF unwinder for stacktraces" arch/sh/Kconfig.debug- depends on DEBUG_KERNEL arch/sh/Kconfig.debug: select FRAME_POINTER

You should make sure that cannot happen when CONFIG_FUNCTION_TRACER is enabled. I.e. make DWARF_UNWINDER depend on !FUNCTION_TRACER?

Other architectures do something similar:

arch/sparc/Kconfig.debug:config FRAME_POINTER
arch/sparc/Kconfig.debug- bool
arch/sparc/Kconfig.debug- depends on MCOUNT

arch/x86/Kconfig.debug:config FRAME_POINTER arch/x86/Kconfig.debug- depends on !UNWINDER_ORC && !UNWINDER_GUESS arch/x86/Kconfig.debug- bool

Probably you need to adjust the following, too:

lib/Kconfig.debug:config FRAME_POINTER
lib/Kconfig.debug- bool "Compile the kernel with frame pointers"
lib/Kconfig.debug- depends on DEBUG_KERNEL && (M68K || UML ||
SUPERH) || ARCH_WANT_FRAME_POINTERS

    lib/Kconfig.debug-      default y if (DEBUG_INFO && UML) ||

ARCH_WANT_FRAME_POINTERS

i.e. drop SUPERH from the list above, and select ARCH_WANT_FRAME_POINTERS if !FUNCTION_TRACER.

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

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

#28 lore raw

Re: [PATCH 7/7 v4] sh: mcount.S: fix build error when PRINTK is not enabled

In reply to Geert Uytterhoeven

Hi Geert!

Quoted 46 lines · Geert Uytterhoeven

Oops, obviously all of that happened before my morning coffee ;-)

Makefile has:

ifdef CONFIG_FRAME_POINTER
KBUILD_CFLAGS += -fno-omit-frame-pointer -fno-optimize-sibling-calls
KBUILD_RUSTFLAGS += -Cforce-frame-pointers=y
else
# Some targets (ARM with Thumb2, for example), can't be built with frame # pointers. For those, we don't have FUNCTION_TRACER automatically # select FRAME_POINTER. However, FUNCTION_TRACER adds -pg, and this is # incompatible with -fomit-frame-pointer with current GCC, so we don't use # -fomit-frame-pointer with FUNCTION_TRACER.
# In the Rust target specification, "frame-pointer" is set explicitly # to "may-omit".
ifndef CONFIG_FUNCTION_TRACER
KBUILD_CFLAGS += -fomit-frame-pointer
endif
endif

Your config probably has CONFIG_FRAME_POINTER set?

arch/sh/Kconfig.debug=config DWARF_UNWINDER arch/sh/Kconfig.debug- bool "Enable the DWARF unwinder for stacktraces" arch/sh/Kconfig.debug- depends on DEBUG_KERNEL arch/sh/Kconfig.debug: select FRAME_POINTER

You should make sure that cannot happen when CONFIG_FUNCTION_TRACER is enabled. I.e. make DWARF_UNWINDER depend on !FUNCTION_TRACER?

Other architectures do something similar:

arch/sparc/Kconfig.debug:config FRAME_POINTER
arch/sparc/Kconfig.debug- bool
arch/sparc/Kconfig.debug- depends on MCOUNT

arch/x86/Kconfig.debug:config FRAME_POINTER arch/x86/Kconfig.debug- depends on !UNWINDER_ORC && !UNWINDER_GUESS arch/x86/Kconfig.debug- bool

Probably you need to adjust the following, too:

lib/Kconfig.debug:config FRAME_POINTER
lib/Kconfig.debug- bool "Compile the kernel with frame pointers"
lib/Kconfig.debug- depends on DEBUG_KERNEL && (M68K || UML ||
SUPERH) || ARCH_WANT_FRAME_POINTERS

Quoted 5 lines
    lib/Kconfig.debug-      default y if (DEBUG_INFO && UML) ||

ARCH_WANT_FRAME_POINTERS

i.e. drop SUPERH from the list above, and select ARCH_WANT_FRAME_POINTERS if !FUNCTION_TRACER.

Do you think you can send a patch for this change? I can then review and apply it together with Randy's series in case everything works as expected.

Adrian

Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
#29 lore raw

Re: [PATCH 7/7 v4] sh: mcount.S: fix build error when PRINTK is not enabled

In reply to Geert Uytterhoeven

Hi Geert!

Quoted 122 lines · Geert Uytterhoeven

Hi Adrian,

Quoted 64 lines · John Paul Adrian Glaubitz
Quoted 63 lines · Geert Uytterhoeven
Quoted 61 lines · John Paul Adrian Glaubitz
Quoted 25 lines · Randy Dunlap

Fix a build error in mcount.S when CONFIG_PRINTK is not enabled. Fixes this build error:

sh2-linux-ld: arch/sh/lib/mcount.o: in function `stack_panic':
(.text+0xec): undefined reference to `dump_stack'

Fixes e460ab27b6c3 ("sh: Fix up stack overflow check with ftrace disabled.")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: add PRINTK to STACK_DEBUG dependency (thanks, Geert)
v3: skipped
v4: refresh & resend

 arch/sh/Kconfig.debug |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -- a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug

arch/sh/Kconfig.debug config SH_STANDARD_BIOS · line 21

Quoted 8 lines
arch/sh/Kconfig.debug +1 -1
@@ -15,7 +15,7 @@ config SH_STANDARD_BIOS
 
 config STACK_DEBUG
      bool "Check for stack overflows"
-     depends on DEBUG_KERNEL
+     depends on DEBUG_KERNEL && PRINTK
      help
        This option will cause messages to be printed if free stack space
        drops below a certain limit. Saying Y here will add overhead to

I can't really test this change as the moment I am enabling CONFIG_STACK_DEBUG, the build fails with:

CC scripts/mod/devicetable-offsets.s
sh4-linux-gcc: error: -pg and -fomit-frame-pointer are incompatible make[1]: *** [scripts/Makefile.build:252: scripts/mod/empty.o] Error 1 make[1]: *** Waiting for unfinished jobs....
sh4-linux-gcc: error: -pg and -fomit-frame-pointer are incompatible make[1]: *** [scripts/Makefile.build:114: scripts/mod/devicetable-offsets.s] Error 1
make: *** [Makefile:1286: prepare0] Error 2

So, I assume we need to strip -fomit-frame-pointer from KBUILD_CFLAGS, correct?

I tried this change, but that doesn't fix it for me:

arch/sh/Makefile +1 -0
index 5c8776482530..83f535b73835 100644
@@ -173,6 +173,7 @@ KBUILD_AFLAGS               += $(cflags-y)
 
 ifeq ($(CONFIG_MCOUNT),y)
   KBUILD_CFLAGS += -pg
+  KBUILD_CFLAGS := $(subst -fomit-frame-pointer,,$(KBUILD_CFLAGS))
 endif
 
Quoted 7 lines
Quoted 5 lines
Quoted 3 lines
arch/sh/Makefile +0 -0
 ifeq ($(CONFIG_DWARF_UNWINDER),y)

Any ideas?

Please try with "+=" instead of ":=".

That doesn't work either. I tried the following, but that didn't strip -fomit-frame-pointer:

Oops, obviously all of that happened before my morning coffee ;-)

Makefile has:

ifdef CONFIG_FRAME_POINTER
KBUILD_CFLAGS += -fno-omit-frame-pointer -fno-optimize-sibling-calls
KBUILD_RUSTFLAGS += -Cforce-frame-pointers=y
else
# Some targets (ARM with Thumb2, for example), can't be built with frame # pointers. For those, we don't have FUNCTION_TRACER automatically # select FRAME_POINTER. However, FUNCTION_TRACER adds -pg, and this is # incompatible with -fomit-frame-pointer with current GCC, so we don't use # -fomit-frame-pointer with FUNCTION_TRACER.
# In the Rust target specification, "frame-pointer" is set explicitly # to "may-omit".
ifndef CONFIG_FUNCTION_TRACER
KBUILD_CFLAGS += -fomit-frame-pointer
endif
endif

Your config probably has CONFIG_FRAME_POINTER set?

arch/sh/Kconfig.debug=config DWARF_UNWINDER arch/sh/Kconfig.debug- bool "Enable the DWARF unwinder for stacktraces" arch/sh/Kconfig.debug- depends on DEBUG_KERNEL arch/sh/Kconfig.debug: select FRAME_POINTER

You should make sure that cannot happen when CONFIG_FUNCTION_TRACER is enabled. I.e. make DWARF_UNWINDER depend on !FUNCTION_TRACER?

Other architectures do something similar:

arch/sparc/Kconfig.debug:config FRAME_POINTER
arch/sparc/Kconfig.debug- bool
arch/sparc/Kconfig.debug- depends on MCOUNT

arch/x86/Kconfig.debug:config FRAME_POINTER arch/x86/Kconfig.debug- depends on !UNWINDER_ORC && !UNWINDER_GUESS arch/x86/Kconfig.debug- bool

Probably you need to adjust the following, too:

lib/Kconfig.debug:config FRAME_POINTER
lib/Kconfig.debug- bool "Compile the kernel with frame pointers"
lib/Kconfig.debug- depends on DEBUG_KERNEL && (M68K || UML ||
SUPERH) || ARCH_WANT_FRAME_POINTERS

Quoted 5 lines
    lib/Kconfig.debug-      default y if (DEBUG_INFO && UML) ||

ARCH_WANT_FRAME_POINTERS

i.e. drop SUPERH from the list above, and select ARCH_WANT_FRAME_POINTERS if !FUNCTION_TRACER.

This change fixed it for me:

arch/sh/Kconfig +1 -0
index 98e43a537826..04d310ee7384 100644
@@ -55,6 +55,7 @@ config SUPERH
        select HAVE_SOFTIRQ_ON_OWN_STACK if IRQSTACKS
        select HAVE_STACKPROTECTOR
        select HAVE_SYSCALL_TRACEPOINTS
+       select ARCH_WANT_FRAME_POINTERS
        select IRQ_FORCED_THREADING
        select MODULES_USE_ELF_RELA
        select NEED_SG_DMA_LENGTH
lib/Kconfig.debug +1 -1
index c8b379e2e9ad..3cf45d8edace 100644
@@ -523,7 +523,7 @@ config ARCH_WANT_FRAME_POINTERS
 
 config FRAME_POINTER
        bool "Compile the kernel with frame pointers"
-       depends on DEBUG_KERNEL && (M68K || UML || SUPERH) || ARCH_WANT_FRAME_POINTERS
+       depends on DEBUG_KERNEL && (M68K || UML) || ARCH_WANT_FRAME_POINTERS
        default y if (DEBUG_INFO && UML) || ARCH_WANT_FRAME_POINTERS
        help
          If you say Y here the resulting kernel image will be slightly

It seems this is also what the other architectures do it seems.

Adrian

Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
maintainer Reviewed-by on v4 7/7
#30 lore raw

Re: [PATCH 7/7 v4] sh: mcount.S: fix build error when PRINTK is not enabled

In reply to Randy Dunlap
Quoted 25 lines · Randy Dunlap

Fix a build error in mcount.S when CONFIG_PRINTK is not enabled. Fixes this build error:

sh2-linux-ld: arch/sh/lib/mcount.o: in function `stack_panic':
(.text+0xec): undefined reference to `dump_stack'

Fixes e460ab27b6c3 ("sh: Fix up stack overflow check with ftrace disabled.")
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>

---
v2: add PRINTK to STACK_DEBUG dependency (thanks, Geert)
v3: skipped
v4: refresh & resend

 arch/sh/Kconfig.debug |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -- a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug

arch/sh/Kconfig.debug config SH_STANDARD_BIOS · line 21

Quoted 8 lines
arch/sh/Kconfig.debug +1 -1
@@ -15,7 +15,7 @@ config SH_STANDARD_BIOS
 
 config STACK_DEBUG
 	bool "Check for stack overflows"
-	depends on DEBUG_KERNEL
+	depends on DEBUG_KERNEL && PRINTK
 	help
 	  This option will cause messages to be printed if free stack space
 	  drops below a certain limit. Saying Y here will add overhead to
Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
#31 lore raw
In reply to Randy Dunlap

Hi Randy!

Quoted 31 lines · Randy Dunlap

All of these patches have been sent previously, anywhere from one to 3 times. All patches are now called "v4".

This refresh/resend is to assist the new SH maintainer.

[PATCH 1/7 v4] sh: SH2007: drop the bad URL info
[PATCH 2/7 v4] sh: nmi_debug: fix return value of __setup handler [PATCH 3/7 v4] sh: init: use OF_EARLY_FLATTREE for early init [PATCH 4/7 v4] sh: math-emu: fix macro redefined warning [PATCH 5/7 v4] sh: remove sh5/sh64 last fragments
[PATCH 6/7 v4] sh: fix Kconfig entry for NUMA => SMP
[PATCH 7/7 v4] sh: mcount.S: fix build error when PRINTK is not enabled

diffstat:

 Documentation/kbuild/kbuild.rst                           |    1 -
 Documentation/scheduler/sched-arch.rst                    |    2 --
 Documentation/translations/zh_CN/scheduler/sched-arch.rst |    2 --
 arch/sh/Kconfig                                           |    4 ++++
 arch/sh/Kconfig.debug                                     |    2 +-
 arch/sh/boards/Kconfig                                    |    1 -
 arch/sh/kernel/head_32.S                                  |    6 +++---
 arch/sh/kernel/nmi_debug.c                                |    4 ++--
 arch/sh/kernel/setup.c                                    |    4 ++--
 arch/sh/math-emu/sfp-util.h                               |    4 ----
 scripts/checkstack.pl                                     |    7 -------
 tools/perf/arch/common.c                                  |    2 --
 tools/scripts/Makefile.arch                               |    5 -----
 tools/testing/selftests/mm/Makefile                       |    2 +-
 tools/testing/selftests/mm/run_vmtests.sh                 |    2 +-
 15 files changed, 14 insertions(+), 34 deletions(-)
Quoted 9 lines
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>
Cc Geert Uytterhoeven <[email protected]>
Cc Hitoshi Mitake <[email protected]>
Cc Frank Rowand <[email protected]>
Cc Arnd Bergmann <[email protected]>

Thanks for these fixes. All changes look good to me and I'm going to test them on my SH-7785LCR board on top of 6.3-rc1 and report back. The documentation changes obviously won't have any impact in this regard.

Adrian

Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
#32 lore raw
In reply to Randy Dunlap

Hi Randy!

Quoted 5 lines · Randy Dunlap

All of these patches have been sent previously, anywhere from one to 3 times. All patches are now called "v4".

This refresh/resend is to assist the new SH maintainer.

Quoted 7 lines

[PATCH 1/7 v4] sh: SH2007: drop the bad URL info
[PATCH 2/7 v4] sh: nmi_debug: fix return value of __setup handler [PATCH 3/7 v4] sh: init: use OF_EARLY_FLATTREE for early init [PATCH 4/7 v4] sh: math-emu: fix macro redefined warning [PATCH 5/7 v4] sh: remove sh5/sh64 last fragments
[PATCH 6/7 v4] sh: fix Kconfig entry for NUMA => SMP
[PATCH 7/7 v4] sh: mcount.S: fix build error when PRINTK is not enabled

I have successfully applied, built and booted all patches on my SH7785LCR evaluation board except for patch #5.

I'll do the review next, then include them in my for-next tree for 6.4.

Adrian

Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
#33 lore raw
In reply to Randy Dunlap

Hi Randy!

Quoted 31 lines · Randy Dunlap

All of these patches have been sent previously, anywhere from one to 3 times. All patches are now called "v4".

This refresh/resend is to assist the new SH maintainer.

[PATCH 1/7 v4] sh: SH2007: drop the bad URL info
[PATCH 2/7 v4] sh: nmi_debug: fix return value of __setup handler [PATCH 3/7 v4] sh: init: use OF_EARLY_FLATTREE for early init [PATCH 4/7 v4] sh: math-emu: fix macro redefined warning [PATCH 5/7 v4] sh: remove sh5/sh64 last fragments
[PATCH 6/7 v4] sh: fix Kconfig entry for NUMA => SMP
[PATCH 7/7 v4] sh: mcount.S: fix build error when PRINTK is not enabled

diffstat:

 Documentation/kbuild/kbuild.rst                           |    1 -
 Documentation/scheduler/sched-arch.rst                    |    2 --
 Documentation/translations/zh_CN/scheduler/sched-arch.rst |    2 --
 arch/sh/Kconfig                                           |    4 ++++
 arch/sh/Kconfig.debug                                     |    2 +-
 arch/sh/boards/Kconfig                                    |    1 -
 arch/sh/kernel/head_32.S                                  |    6 +++---
 arch/sh/kernel/nmi_debug.c                                |    4 ++--
 arch/sh/kernel/setup.c                                    |    4 ++--
 arch/sh/math-emu/sfp-util.h                               |    4 ----
 scripts/checkstack.pl                                     |    7 -------
 tools/perf/arch/common.c                                  |    2 --
 tools/scripts/Makefile.arch                               |    5 -----
 tools/testing/selftests/mm/Makefile                       |    2 +-
 tools/testing/selftests/mm/run_vmtests.sh                 |    2 +-
 15 files changed, 14 insertions(+), 34 deletions(-)
Quoted 9 lines
Cc John Paul Adrian Glaubitz <[email protected]>
Cc Yoshinori Sato <[email protected]>
Cc Rich Felker <[email protected]>
Cc Geert Uytterhoeven <[email protected]>
Cc Hitoshi Mitake <[email protected]>
Cc Frank Rowand <[email protected]>
Cc Arnd Bergmann <[email protected]>

All applied to sh-linux/for-next now except for patch number 6.

Apologies that it took so long, I'm still learning :-).

Adrian

Signature · 4 lines
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913