Skip to contentSkip to conversation

MN10300: Remove checks for GDBSTUB related Kconfig macros

PATCH In review Paul Bolle 1 participant 1 message Sep 18, 2014

lore
Share & tools
lore

Paul Bolle

author
#0 lore raw

PATCH 4/5 MN10300: Remove checks for GDBSTUB related Kconfig macros

All Kconfig symbols (indirectly) depending on GDBSTUB were removed. Now remove the checks for their macros and all dead code hidden behind them.

---
 arch/mn10300/boot/compressed/misc.c             |   9 -
 arch/mn10300/include/asm/gdb-stub.h             |  21 --
 arch/mn10300/kernel/Makefile                    |   2 -
 arch/mn10300/kernel/gdb-io-serial-low.S         |  91 -------
 arch/mn10300/kernel/gdb-io-serial.c             | 174 --------------
 arch/mn10300/kernel/gdb-io-ttysm-low.S          |  93 --------
 arch/mn10300/kernel/gdb-io-ttysm.c              | 303 ------------------------
 arch/mn10300/kernel/mn10300-serial.c            |   9 -
 arch/mn10300/kernel/mn10300-serial.h            |  14 --
 arch/mn10300/unit-asb2303/include/unit/serial.h |  85 -------
 arch/mn10300/unit-asb2305/include/unit/serial.h |  78 ------
 arch/mn10300/unit-asb2305/unit-init.c           |   2 -
 arch/mn10300/unit-asb2364/include/unit/serial.h |  66 ------
 13 files changed, 947 deletions(-)
 delete mode 100644 arch/mn10300/kernel/gdb-io-serial-low.S
 delete mode 100644 arch/mn10300/kernel/gdb-io-serial.c
 delete mode 100644 arch/mn10300/kernel/gdb-io-ttysm-low.S
 delete mode 100644 arch/mn10300/kernel/gdb-io-ttysm.c
arch/mn10300/boot/compressed/misc.c +0 -9
index 42cbd77bd439..14a1f0b2dbf8 100644
@@ -14,7 +14,6 @@
 #include <asm/serial-regs.h>
 #include "misc.h"
 
-#ifndef CONFIG_GDBSTUB_ON_TTYSx
 /* display 'Uncompressing Linux... ' messages on ttyS0 or ttyS1 */
 #if 1	/* ttyS0 */
 #define CYG_DEV_BASE	0xA6FB0000
@@ -43,7 +42,6 @@
 	do { CYG_DEV_MCR &= ~SIO_MCR_##LINE; } while (0)
 #define FLOWCTL_SET(LINE) \
 	do { CYG_DEV_MCR |= SIO_MCR_##LINE; } while (0)
-#endif
 
 /*
  * gzip declarations
@@ -211,7 +209,6 @@ static inline void kputchar(unsigned char ch)
 static void kputs(const char *s)
 {
 #ifdef CONFIG_DEBUG_DECOMPRESS_KERNEL
-#ifndef CONFIG_GDBSTUB_ON_TTYSx
 	char ch;
 
 	FLOWCTL_SET(DTR);
@@ -228,12 +225,6 @@ static void kputs(const char *s)
 	}
 
 	FLOWCTL_CLEAR(DTR);
-#else
-
-	for (; *s; s++)
-		kputchar(*s);
-
-#endif
 #endif /* CONFIG_DEBUG_DECOMPRESS_KERNEL */
 }
 
arch/mn10300/include/asm/gdb-stub.h +0 -21
index f5495ad82b77..8aa71a966d00 100644
@@ -144,39 +144,18 @@ extern u8	gdbstub_rx_overflow;
 extern u8	gdbstub_busy;
 extern u8	gdbstub_rx_unget;
 
-#ifdef CONFIG_GDBSTUB_DEBUGGING
-extern void gdbstub_printk(const char *fmt, ...)
-	__attribute__((format(printf, 1, 2)));
-#else
 static inline __attribute__((format(printf, 1, 2)))
 void gdbstub_printk(const char *fmt, ...)
 {
 }
-#endif
 
-#ifdef CONFIG_GDBSTUB_DEBUG_ENTRY
-#define gdbstub_entry(FMT, ...) gdbstub_printk(FMT, ##__VA_ARGS__)
-#else
 #define gdbstub_entry(FMT, ...) no_printk(FMT, ##__VA_ARGS__)
-#endif
 
-#ifdef CONFIG_GDBSTUB_DEBUG_PROTOCOL
-#define gdbstub_proto(FMT, ...) gdbstub_printk(FMT, ##__VA_ARGS__)
-#else
 #define gdbstub_proto(FMT, ...) no_printk(FMT, ##__VA_ARGS__)
-#endif
 
-#ifdef CONFIG_GDBSTUB_DEBUG_IO
-#define gdbstub_io(FMT, ...) gdbstub_printk(FMT, ##__VA_ARGS__)
-#else
 #define gdbstub_io(FMT, ...) no_printk(FMT, ##__VA_ARGS__)
-#endif
 
-#ifdef CONFIG_GDBSTUB_DEBUG_BREAKPOINT
-#define gdbstub_bkpt(FMT, ...) gdbstub_printk(FMT, ##__VA_ARGS__)
-#else
 #define gdbstub_bkpt(FMT, ...) no_printk(FMT, ##__VA_ARGS__)
-#endif
 
 #endif /* !__ASSEMBLY__ */
 #endif /* _ASM_GDB_STUB_H */
arch/mn10300/kernel/Makefile +0 -2
index ce9f01778a86..1ddc8e22c628 100644
@@ -17,8 +17,6 @@ obj-$(CONFIG_MN10300_WD_TIMER) += mn10300-watchdog.o mn10300-watchdog-low.o
 
 obj-$(CONFIG_MN10300_TTYSM) += mn10300-serial.o mn10300-serial-low.o \
 			       mn10300-debug.o
-obj-$(CONFIG_GDBSTUB_ON_TTYSx) += gdb-io-serial.o gdb-io-serial-low.o
-obj-$(CONFIG_GDBSTUB_ON_TTYSMx) += gdb-io-ttysm.o gdb-io-ttysm-low.o
 
 obj-$(CONFIG_MN10300_RTC) += rtc.o
 obj-$(CONFIG_PROFILE) += profile.o profile-low.o
arch/mn10300/kernel/gdb-io-serial-low.S deleted +0 -91

91 lines not on this page · raw message

arch/mn10300/kernel/gdb-io-serial.c deleted +0 -174

174 lines not on this page · raw message

arch/mn10300/kernel/gdb-io-ttysm-low.S deleted +0 -93

93 lines not on this page · raw message

arch/mn10300/kernel/gdb-io-ttysm.c deleted +0 -303

303 lines not on this page · raw message

arch/mn10300/kernel/mn10300-serial.c +0 -9
index 7ecf69879e2d..bbfccd44b06e 100644
@@ -205,9 +205,6 @@ struct mn10300_serial_port mn10300_serial_port_sif0 = {
 	.tx_icr		= &GxICR(SC0TXIRQ),
 	.clock_src	= MNSCx_CLOCK_SRC_IOCLK,
 	.options	= 0,
-#ifdef CONFIG_GDBSTUB_ON_TTYSM0
-	.gdbstub	= 1,
-#endif
 };
 #endif /* CONFIG_MN10300_TTYSM0 */
 
@@ -267,9 +264,6 @@ struct mn10300_serial_port mn10300_serial_port_sif1 = {
 	.tx_icr		= &GxICR(SC1TXIRQ),
 	.clock_src	= MNSCx_CLOCK_SRC_IOCLK,
 	.options	= 0,
-#ifdef CONFIG_GDBSTUB_ON_TTYSM1
-	.gdbstub	= 1,
-#endif
 };
 #endif /* CONFIG_MN10300_TTYSM1 */
 
@@ -344,9 +338,6 @@ struct mn10300_serial_port mn10300_serial_port_sif2 = {
 #else
 	.options	= 0,
 #endif
-#ifdef CONFIG_GDBSTUB_ON_TTYSM2
-	.gdbstub	= 1,
-#endif
 };
 #endif /* CONFIG_MN10300_TTYSM2 */
 
arch/mn10300/kernel/mn10300-serial.h +0 -14
index 01791c68ea1f..990a31c45e9f 100644
@@ -113,18 +113,4 @@ extern asmlinkage void mn10300_serial_vdma_tx_handler(void);
 
 #endif /* __ASSEMBLY__ */
 
-#if defined(CONFIG_GDBSTUB_ON_TTYSM0)
-#define SCgSTR SC0STR
-#define SCgRXB SC0RXB
-#define SCgRXIRQ SC0RXIRQ
-#elif defined(CONFIG_GDBSTUB_ON_TTYSM1)
-#define SCgSTR SC1STR
-#define SCgRXB SC1RXB
-#define SCgRXIRQ SC1RXIRQ
-#elif defined(CONFIG_GDBSTUB_ON_TTYSM2)
-#define SCgSTR SC2STR
-#define SCgRXB SC2RXB
-#define SCgRXIRQ SC2RXIRQ
-#endif
-
 #endif /* _MN10300_SERIAL_H */
arch/mn10300/unit-asb2303/include/unit/serial.h +0 -85

100 lines not on this page · raw message

arch/mn10300/unit-asb2305/include/unit/serial.h +0 -78

93 lines not on this page · raw message

arch/mn10300/unit-asb2305/unit-init.c +0 -2
index bc4adfaf815c..674f3e960cb2 100644
@@ -25,12 +25,10 @@
  */
 asmlinkage void __init unit_init(void)
 {
-#ifndef CONFIG_GDBSTUB_ON_TTYSx
 	/* set the 16550 interrupt line to level 3 if not being used for GDB */
 #ifdef CONFIG_EXT_SERIAL_IRQ_LEVEL
 	set_intr_level(XIRQ0, NUM2GxICR_LEVEL(CONFIG_EXT_SERIAL_IRQ_LEVEL));
 #endif
-#endif /* CONFIG_GDBSTUB_ON_TTYSx */
 }
 
 /*
arch/mn10300/unit-asb2364/include/unit/serial.h +0 -66

83 lines not on this page · raw message

Signature · 1 line
1.9.3