Commit 2e113f39 authored by Russell King's avatar Russell King

[SERIAL] Fix buglet causing (eg) ttyS-14

Allocate positive instead of negative line numbers when 8250.c
registers a new port with the core.  This bug could cause
registrations to erroneously fail, or oopsen when the pcmcia
serial device is ejected.
parent 739c9fda
...@@ -2425,7 +2425,7 @@ int uart_register_port(struct uart_driver *drv, struct uart_port *port) ...@@ -2425,7 +2425,7 @@ int uart_register_port(struct uart_driver *drv, struct uart_port *port)
state->port->regshift = port->regshift; state->port->regshift = port->regshift;
state->port->iotype = port->iotype; state->port->iotype = port->iotype;
state->port->flags = port->flags; state->port->flags = port->flags;
state->port->line = drv->state - state; state->port->line = state - drv->state;
__uart_register_port(drv, state, state->port); __uart_register_port(drv, state, state->port);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment