aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHelge Deller <deller@gmx.de>2009-01-13 16:51:07 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2009-01-13 17:03:43 -0500
commit125c97d8a59888c5678734c2b70cbd08c847bd99 (patch)
tree39a22727dbbf543d457d73c91cc9b6b9db164f8e
parente0b325d310a6b11f1538413fd557d2eb98f2fae5 (diff)
fix early_serial_setup() regression
Commit b430428a188e8a434325e251d0704af4b88b4711 ("8250: Don't clobber spinlocks.") introduced a regression on the parisc architecture, which broke the handover to the serial port at boottime. early_serial_setup() was changed to only copy a subset of the uart_port fields, and sadly the "type" and "line" fields were forgotten and thus the serial port was not initialized and could not be used for a handover. This patch fixes this by copying the missing fields. As this change to early_serial_setup() doesn't need an initialized spinlock in the uart_port struct any longer, we can drop the spinlock initialization in the superio driver. Cc: David Daney <ddaney@caviumnetworks.com> Cc: Tomaso Paoletti <tpaoletti@caviumnetworks.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Acked-by: Kyle McMartin <kyle@mcmartin.ca> Cc: linux-parisc@vger.kernel.org Signed-off-by: Helge Deller <deller@gmx.de> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--drivers/parisc/superio.c1
-rw-r--r--drivers/serial/8250.c2
2 files changed, 2 insertions, 1 deletions
diff --git a/drivers/parisc/superio.c b/drivers/parisc/superio.c
index 1e93c837514f..4fa3bb2ddfe4 100644
--- a/drivers/parisc/superio.c
+++ b/drivers/parisc/superio.c
@@ -405,7 +405,6 @@ static void __init superio_serial_init(void)
405 serial_port.type = PORT_16550A; 405 serial_port.type = PORT_16550A;
406 serial_port.uartclk = 115200*16; 406 serial_port.uartclk = 115200*16;
407 serial_port.fifosize = 16; 407 serial_port.fifosize = 16;
408 spin_lock_init(&serial_port.lock);
409 408
410 /* serial port #1 */ 409 /* serial port #1 */
411 serial_port.iobase = sio_dev.sp1_base; 410 serial_port.iobase = sio_dev.sp1_base;
diff --git a/drivers/serial/8250.c b/drivers/serial/8250.c
index 1889a63ebc22..0d934bfbdd9b 100644
--- a/drivers/serial/8250.c
+++ b/drivers/serial/8250.c
@@ -2839,6 +2839,8 @@ int __init early_serial_setup(struct uart_port *port)
2839 p->flags = port->flags; 2839 p->flags = port->flags;
2840 p->mapbase = port->mapbase; 2840 p->mapbase = port->mapbase;
2841 p->private_data = port->private_data; 2841 p->private_data = port->private_data;
2842 p->type = port->type;
2843 p->line = port->line;
2842 2844
2843 set_io_from_upio(p); 2845 set_io_from_upio(p);
2844 if (port->serial_in) 2846 if (port->serial_in)