11 #include <linux/string.h>
12 #include <linux/kernel.h>
13 #include <linux/signal.h>
14 #include <linux/sched.h>
20 #include <asm/pgtable.h>
21 #include <asm/gdb-stub.h>
22 #include <asm/exceptions.h>
23 #include <asm/serial-regs.h>
24 #include <unit/serial.h>
45 XIRQxICR(GDBPORT_SERIAL_IRQ) = 0;
46 tmp = XIRQxICR(GDBPORT_SERIAL_IRQ);
48 #if CONFIG_GDBSTUB_IRQ_LEVEL == 0
50 #elif CONFIG_GDBSTUB_IRQ_LEVEL == 1
52 #elif CONFIG_GDBSTUB_IRQ_LEVEL == 2
54 #elif CONFIG_GDBSTUB_IRQ_LEVEL == 3
56 #elif CONFIG_GDBSTUB_IRQ_LEVEL == 4
58 #elif CONFIG_GDBSTUB_IRQ_LEVEL == 5
61 #error "Unknown irq level for gdbstub."
67 XIRQxICR(GDBPORT_SERIAL_IRQ) &= ~GxICR_REQUEST;
68 XIRQxICR(GDBPORT_SERIAL_IRQ) =
69 GxICR_ENABLE | NUM2GxICR_LEVEL(CONFIG_GDBSTUB_IRQ_LEVEL);
70 tmp = XIRQxICR(GDBPORT_SERIAL_IRQ);
75 arch_local_change_intr_mask_level(
76 NUM2EPSW_IM(CONFIG_GDBSTUB_IRQ_LEVEL + 1));
87 value = 18432000 / 16 /
baud;
89 lcr = GDBPORT_SERIAL_LCR;
91 GDBPORT_SERIAL_DLL = value & 0xff;
92 GDBPORT_SERIAL_DLM = (value >> 8) & 0xff;
93 GDBPORT_SERIAL_LCR =
lcr;
103 #if defined(CONFIG_MN10300_WD_TIMER)
122 #ifdef CONFIG_MN10300_WD_TIMER
123 for (cpu = 0; cpu <
NR_CPUS; cpu++)
157 GDBPORT_SERIAL_TX = 0x0d;
161 GDBPORT_SERIAL_TX = ch;