#include <linux/init.h>
#include <linux/console.h>
#include <linux/sysrq.h>
+#include <linux/mca.h>
#include <linux/delay.h>
#include <linux/device.h>
#include <linux/tty.h>
#include <asm/irq.h>
#include "8250.h"
-#ifdef CONFIG_KDB
-#include <linux/kdb.h>
-/*
- * kdb_serial_line records the serial line number of the first serial console.
- * NOTE: The kernel ignores characters on the serial line unless a user space
- * program has opened the line first. To enter kdb before user space has opened
- * the serial line, you can use the 'kdb=early' flag to lilo and set the
- * appropriate breakpoints.
- */
-
-static int kdb_serial_line = -1;
-static const char *kdb_serial_ptr = kdb_serial_str;
-#endif /* CONFIG_KDB */
#ifndef NO_PC_LEGACY_SERIAL_8250_CONSOLE
#define do_not_try_pc_legacy_8250_console (0)
bytes but must do so to clear interrupts */
}
ch = serial_inp(up, UART_RX);
-#ifdef CONFIG_KDB
- if ((up->port.line == kdb_serial_line) && kdb_on) {
- if (ch == *kdb_serial_ptr) {
- if (!(*++kdb_serial_ptr)) {
- kdb(KDB_REASON_KEYBOARD, 0, regs);
- kdb_serial_ptr = kdb_serial_str;
- break;
- }
- } else
- kdb_serial_ptr = kdb_serial_str;
- }
-#endif /* CONFIG_KDB */
flag = TTY_NORMAL;
up->port.icount.rx++;
int probeflags = PROBE_ANY;
int ret;
-#ifdef CONFIG_MCA
/*
* Don't probe for MCA ports on non-MCA machines.
*/
if (up->port.flags & UPF_BOOT_ONLYMCA && !MCA_bus)
return;
-#endif
/*
* Find the region that we can probe for. This in turn
if (!port->iobase && !port->membase)
return -ENODEV;
-#ifdef CONFIG_KDB
- /*
- * Remember the line number of the first serial
- * console. We'll make this the kdb serial console too.
- */
- if (kdb_serial_line == -1) {
- kdb_serial_line = co->index;
- kdb_serial.io_type = port->iotype;
- switch (port->iotype) {
- case SERIAL_IO_MEM:
-#ifdef SERIAL_IO_MEM32
- case SERIAL_IO_MEM32:
-#endif
- kdb_serial.iobase = (unsigned long)(port->membase);
- kdb_serial.ioreg_shift = port->regshift;
- break;
- default:
- kdb_serial.iobase = port->iobase;
- kdb_serial.ioreg_shift = 0;
- break;
- }
- }
-#endif /* CONFIG_KDB */
-
if (options)
uart_parse_options(options, &baud, &parity, &bits, &flow);