Skip to content

Commit cae19b5

Browse files
committed
sh: Kill off legacy UBC wakeup cruft.
This code was added for some ancient SH-4 solution engines with peculiar boot ROMs that did silly things to the UBC MSTP bits. None of these have been in the wild for years, and these days the clock framework wraps up the MSTP bits, meaning that the UBC code is one of the few interfaces that is stomping MSTP bits underneath the clock framework. At this point the risks far outweigh any benefit this code provided, so just kill it off. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
1 parent 78aed4a commit cae19b5

5 files changed

Lines changed: 0 additions & 93 deletions

File tree

‎arch/sh/Kconfig‎

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -757,17 +757,6 @@ config ENTRY_OFFSET
757757
default "0x00010000" if PAGE_SIZE_64KB
758758
default "0x00000000"
759759

760-
config UBC_WAKEUP
761-
bool "Wakeup UBC on startup"
762-
depends on CPU_SH4 && !CPU_SH4A
763-
help
764-
Selecting this option will wakeup the User Break Controller (UBC) on
765-
startup. Although the UBC is left in an awake state when the processor
766-
comes up, some boot loaders misbehave by putting the UBC to sleep in a
767-
power saving state, which causes issues with things like ptrace().
768-
769-
If unsure, say N.
770-
771760
choice
772761
prompt "Kernel command line"
773762
optional

‎arch/sh/include/asm/ubc.h‎

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -60,16 +60,5 @@
6060
#define BRCR_UBDE (1 << 0)
6161
#endif
6262

63-
#ifndef __ASSEMBLY__
64-
/* arch/sh/kernel/cpu/ubc.S */
65-
extern void ubc_sleep(void);
66-
67-
#ifdef CONFIG_UBC_WAKEUP
68-
extern void ubc_wakeup(void);
69-
#else
70-
#define ubc_wakeup() do { } while (0)
71-
#endif
72-
#endif
73-
7463
#endif /* __KERNEL__ */
7564
#endif /* __ASM_SH_UBC_H */

‎arch/sh/kernel/cpu/Makefile‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ obj-$(CONFIG_ARCH_SHMOBILE) += shmobile/
1515

1616
# Common interfaces.
1717

18-
obj-$(CONFIG_UBC_WAKEUP) += ubc.o
1918
obj-$(CONFIG_SH_ADC) += adc.o
2019
obj-$(CONFIG_SH_CLK_CPG) += clock-cpg.o
2120

‎arch/sh/kernel/cpu/init.c‎

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -338,17 +338,6 @@ asmlinkage void __init sh_cpu_init(void)
338338
}
339339
#endif
340340

341-
/*
342-
* Some brain-damaged loaders decided it would be a good idea to put
343-
* the UBC to sleep. This causes some issues when it comes to things
344-
* like PTRACE_SINGLESTEP or doing hardware watchpoints in GDB. So ..
345-
* we wake it up and hope that all is well.
346-
*/
347-
#ifdef CONFIG_SUPERH32
348-
if (raw_smp_processor_id() == 0)
349-
ubc_wakeup();
350-
#endif
351-
352341
speculative_execution_init();
353342
expmask_init();
354343
}

‎arch/sh/kernel/cpu/ubc.S‎

Lines changed: 0 additions & 59 deletions
This file was deleted.

0 commit comments

Comments
 (0)