summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRussell King <rmk@flint.arm.linux.org.uk>2002-10-12 02:02:54 +0100
committerRussell King <rmk@flint.arm.linux.org.uk>2002-10-12 02:02:54 +0100
commit7c05bbf9ea019d85b8df7dbb60052bc1872254e5 (patch)
tree739ed8c611c01f5d939323e3cfc3b3b6b9d6b914
parentf7353c674b6404b33bdd6429403b314e8ce29af0 (diff)
parent92b0797e241af63866faaeb3a4cf097e0d7359dd (diff)
Merge http://linux.bkbits.net/linux-2.5
into flint.arm.linux.org.uk:/usr/src/linux-bk-2.5/linux-2.5-rmk
-rw-r--r--drivers/serial/8250.c3
-rw-r--r--drivers/serial/8250_pci.c6
-rw-r--r--drivers/serial/core.c4
-rw-r--r--include/linux/serialP.h26
4 files changed, 9 insertions, 30 deletions
diff --git a/drivers/serial/8250.c b/drivers/serial/8250.c
index 66807c12f50b..762897492924 100644
--- a/drivers/serial/8250.c
+++ b/drivers/serial/8250.c
@@ -33,7 +33,6 @@
#include <linux/serial_reg.h>
#include <linux/serial.h>
#include <linux/serialP.h>
-#include <linux/serial.h>
#include <linux/delay.h>
#include <asm/io.h>
@@ -1636,7 +1635,7 @@ static void serial8250_config_port(struct uart_port *port, int flags)
if (up->port.type != PORT_RSA && res_rsa)
release_resource(res_rsa);
- if (up->port.type == PORT_UNKNOWN)
+ if (up->port.type == PORT_UNKNOWN && res_std)
release_resource(res_std);
}
diff --git a/drivers/serial/8250_pci.c b/drivers/serial/8250_pci.c
index 866f7bc5048e..0ec02685e078 100644
--- a/drivers/serial/8250_pci.c
+++ b/drivers/serial/8250_pci.c
@@ -22,10 +22,7 @@
#include <linux/slab.h>
#include <linux/serial.h>
-/* 2.4.6 compatibility cruft - to be removed with the old serial.c code */
-#define pci_board __pci_board
#include <linux/serialP.h>
-#undef pci_board
#include <asm/bitops.h>
#include <asm/byteorder.h>
@@ -771,7 +768,8 @@ static void __devexit pci_remove_one(struct pci_dev *dev)
for (i = 0; i < priv->nr; i++)
unregister_serial(priv->line[i]);
- priv->board->init_fn(dev, priv->board, 0);
+ if (priv->board->init_fn)
+ priv->board->init_fn(dev, priv->board, 0);
pci_disable_device(dev);
diff --git a/drivers/serial/core.c b/drivers/serial/core.c
index a5ed63f1b3bd..34c926c533f8 100644
--- a/drivers/serial/core.c
+++ b/drivers/serial/core.c
@@ -1604,8 +1604,6 @@ static int uart_open(struct tty_struct *tty, struct file *filp)
return retval;
}
-#ifdef CONFIG_PROC_FS
-
static const char *uart_type(struct uart_port *port)
{
const char *str = NULL;
@@ -1619,6 +1617,8 @@ static const char *uart_type(struct uart_port *port)
return str;
}
+#ifdef CONFIG_PROC_FS
+
static int uart_line_info(char *buf, struct uart_driver *drv, int i)
{
struct uart_state *state = drv->state + i;
diff --git a/include/linux/serialP.h b/include/linux/serialP.h
index 6fcb341a8776..73541f600528 100644
--- a/include/linux/serialP.h
+++ b/include/linux/serialP.h
@@ -131,6 +131,9 @@ struct rs_multiport_struct {
* Digital did something really horribly wrong with the OUT1 and OUT2
* lines on at least some ALPHA's. The failure mode is that if either
* is cleared, the machine locks up with endless interrupts.
+ *
+ * This is still used by arch/mips/au1000/common/serial.c for some weird
+ * reason (mips != alpha!)
*/
#define ALPHA_KLUDGE_MCR (UART_MCR_OUT2 | UART_MCR_OUT1)
#else
@@ -138,29 +141,8 @@ struct rs_multiport_struct {
#endif
/*
- * Structures and definitions for PCI support
+ * Definitions for PCI support.
*/
-struct pci_dev;
-struct pci_board {
- int flags;
- int num_ports;
- int base_baud;
- int uart_offset;
- int reg_shift;
- int (*init_fn)(struct pci_dev *dev, struct pci_board *board,
- int enable);
- int first_uart_offset;
-};
-
-struct pci_board_inst {
- struct pci_board board;
- struct pci_dev *dev;
-};
-
-#ifndef PCI_ANY_ID
-#define PCI_ANY_ID (~0)
-#endif
-
#define SPCI_FL_BASE_MASK 0x0007
#define SPCI_FL_BASE0 0x0000
#define SPCI_FL_BASE1 0x0001