X-Git-Url: http://ftp.safe.ca/?a=blobdiff_plain;f=drivers%2Fserial%2Fsunhv.c;h=d1eedf13d85cd0773beade7ef70ff20dd5ebbcc4;hb=61c7a080a5a061c976988fd4b844dfb468dda255;hp=e41766d08035643e18b72a2cfb88bf471355d885;hpb=c6ed413ddcfb66e9d3e1318060271391c7659dd3;p=safe%2Fjmp%2Flinux-2.6 diff --git a/drivers/serial/sunhv.c b/drivers/serial/sunhv.c index e41766d..d1eedf1 100644 --- a/drivers/serial/sunhv.c +++ b/drivers/serial/sunhv.c @@ -184,8 +184,8 @@ static struct tty_struct *receive_chars(struct uart_port *port) { struct tty_struct *tty = NULL; - if (port->info != NULL) /* Unopened serial console */ - tty = port->info->port.tty; + if (port->state != NULL) /* Unopened serial console */ + tty = port->state->port.tty; if (sunhv_ops->receive_chars(port, tty)) sun_do_break(); @@ -197,10 +197,10 @@ static void transmit_chars(struct uart_port *port) { struct circ_buf *xmit; - if (!port->info) + if (!port->state) return; - xmit = &port->info->xmit; + xmit = &port->state->xmit; if (uart_circ_empty(xmit) || uart_tx_stopped(port)) return; @@ -461,7 +461,7 @@ static void sunhv_console_write_paged(struct console *con, const char *s, unsign break; udelay(1); } - if (limit <= 0) + if (limit < 0) break; page_bytes -= written; ra += written; @@ -565,8 +565,8 @@ static int __devinit hv_probe(struct of_device *op, const struct of_device_id *m if (err) goto out_free_con_read_page; - sunserial_console_match(&sunhv_console, op->node, - &sunhv_reg, port->line); + sunserial_console_match(&sunhv_console, op->dev.of_node, + &sunhv_reg, port->line, false); err = uart_add_one_port(&sunhv_reg, port); if (err) @@ -616,7 +616,7 @@ static int __devexit hv_remove(struct of_device *dev) return 0; } -static struct of_device_id hv_match[] = { +static const struct of_device_id hv_match[] = { { .name = "console", .compatible = "qcn",