- patches.fixes/patch-2.6.11-rc1: 2.6.11-rc1.
[linux-flexiantxendom0-3.2.10.git] / drivers / serial / 8250.c
index 4397c2f..4a3e6f5 100644 (file)
@@ -31,6 +31,7 @@
 #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)
@@ -1009,18 +997,6 @@ receive_chars(struct uart_8250_port *up, int *status, struct pt_regs *regs)
                           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++;
 
@@ -1890,13 +1866,11 @@ static void serial8250_config_port(struct uart_port *port, int flags)
        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
@@ -2121,30 +2095,6 @@ static int serial8250_console_setup(struct console *co, char *options)
        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);