diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-06-09 00:23:33 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-06-09 00:23:33 -0400 |
commit | 1ba7055af26f008e8fc8dab9dcb1701534afbe16 (patch) | |
tree | 6156556f56eba8ebc6d50639fbc8329f5ad078a2 /drivers/tty/serial/8250 | |
parent | f0f6b80368133411414762d1ce42d983ff618c95 (diff) | |
parent | 317ddd256b9c24b0d78fa8018f80f1e495481a10 (diff) |
Merge 3.10-rc5 into tty-next
Diffstat (limited to 'drivers/tty/serial/8250')
-rw-r--r-- | drivers/tty/serial/8250/8250_core.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c index 46528d57be72..86c00b1c5583 100644 --- a/drivers/tty/serial/8250/8250_core.c +++ b/drivers/tty/serial/8250/8250_core.c | |||
@@ -2755,7 +2755,7 @@ static void __init serial8250_isa_init_ports(void) | |||
2755 | if (nr_uarts > UART_NR) | 2755 | if (nr_uarts > UART_NR) |
2756 | nr_uarts = UART_NR; | 2756 | nr_uarts = UART_NR; |
2757 | 2757 | ||
2758 | for (i = 0; i < UART_NR; i++) { | 2758 | for (i = 0; i < nr_uarts; i++) { |
2759 | struct uart_8250_port *up = &serial8250_ports[i]; | 2759 | struct uart_8250_port *up = &serial8250_ports[i]; |
2760 | struct uart_port *port = &up->port; | 2760 | struct uart_port *port = &up->port; |
2761 | 2761 | ||
@@ -2916,7 +2916,7 @@ static int __init serial8250_console_setup(struct console *co, char *options) | |||
2916 | * if so, search for the first available port that does have | 2916 | * if so, search for the first available port that does have |
2917 | * console support. | 2917 | * console support. |
2918 | */ | 2918 | */ |
2919 | if (co->index >= UART_NR) | 2919 | if (co->index >= nr_uarts) |
2920 | co->index = 0; | 2920 | co->index = 0; |
2921 | port = &serial8250_ports[co->index].port; | 2921 | port = &serial8250_ports[co->index].port; |
2922 | if (!port->iobase && !port->membase) | 2922 | if (!port->iobase && !port->membase) |
@@ -2957,7 +2957,7 @@ int serial8250_find_port(struct uart_port *p) | |||
2957 | int line; | 2957 | int line; |
2958 | struct uart_port *port; | 2958 | struct uart_port *port; |
2959 | 2959 | ||
2960 | for (line = 0; line < UART_NR; line++) { | 2960 | for (line = 0; line < nr_uarts; line++) { |
2961 | port = &serial8250_ports[line].port; | 2961 | port = &serial8250_ports[line].port; |
2962 | if (uart_match_port(p, port)) | 2962 | if (uart_match_port(p, port)) |
2963 | return line; | 2963 | return line; |
@@ -3110,7 +3110,7 @@ static int serial8250_remove(struct platform_device *dev) | |||
3110 | { | 3110 | { |
3111 | int i; | 3111 | int i; |
3112 | 3112 | ||
3113 | for (i = 0; i < UART_NR; i++) { | 3113 | for (i = 0; i < nr_uarts; i++) { |
3114 | struct uart_8250_port *up = &serial8250_ports[i]; | 3114 | struct uart_8250_port *up = &serial8250_ports[i]; |
3115 | 3115 | ||
3116 | if (up->port.dev == &dev->dev) | 3116 | if (up->port.dev == &dev->dev) |
@@ -3178,7 +3178,7 @@ static struct uart_8250_port *serial8250_find_match_or_unused(struct uart_port * | |||
3178 | /* | 3178 | /* |
3179 | * First, find a port entry which matches. | 3179 | * First, find a port entry which matches. |
3180 | */ | 3180 | */ |
3181 | for (i = 0; i < UART_NR; i++) | 3181 | for (i = 0; i < nr_uarts; i++) |
3182 | if (uart_match_port(&serial8250_ports[i].port, port)) | 3182 | if (uart_match_port(&serial8250_ports[i].port, port)) |
3183 | return &serial8250_ports[i]; | 3183 | return &serial8250_ports[i]; |
3184 | 3184 | ||
@@ -3187,7 +3187,7 @@ static struct uart_8250_port *serial8250_find_match_or_unused(struct uart_port * | |||
3187 | * free entry. We look for one which hasn't been previously | 3187 | * free entry. We look for one which hasn't been previously |
3188 | * used (indicated by zero iobase). | 3188 | * used (indicated by zero iobase). |
3189 | */ | 3189 | */ |
3190 | for (i = 0; i < UART_NR; i++) | 3190 | for (i = 0; i < nr_uarts; i++) |
3191 | if (serial8250_ports[i].port.type == PORT_UNKNOWN && | 3191 | if (serial8250_ports[i].port.type == PORT_UNKNOWN && |
3192 | serial8250_ports[i].port.iobase == 0) | 3192 | serial8250_ports[i].port.iobase == 0) |
3193 | return &serial8250_ports[i]; | 3193 | return &serial8250_ports[i]; |
@@ -3196,7 +3196,7 @@ static struct uart_8250_port *serial8250_find_match_or_unused(struct uart_port * | |||
3196 | * That also failed. Last resort is to find any entry which | 3196 | * That also failed. Last resort is to find any entry which |
3197 | * doesn't have a real port associated with it. | 3197 | * doesn't have a real port associated with it. |
3198 | */ | 3198 | */ |
3199 | for (i = 0; i < UART_NR; i++) | 3199 | for (i = 0; i < nr_uarts; i++) |
3200 | if (serial8250_ports[i].port.type == PORT_UNKNOWN) | 3200 | if (serial8250_ports[i].port.type == PORT_UNKNOWN) |
3201 | return &serial8250_ports[i]; | 3201 | return &serial8250_ports[i]; |
3202 | 3202 | ||