X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=drivers%2Fserial%2Fs3c2410.c;h=7410e093a6b9ffa733a4629c947c4d7324ecdcc7;hb=c5111f504d2a9b0d258d7c4752b4093523315989;hp=47681c4654e4d110d1cd76ea4d37752881de8b0c;hpb=3ae5eaec1d2d9c0cf53745352e7d4b152810ba24;p=powerpc.git diff --git a/drivers/serial/s3c2410.c b/drivers/serial/s3c2410.c index 47681c4654..7410e093a6 100644 --- a/drivers/serial/s3c2410.c +++ b/drivers/serial/s3c2410.c @@ -72,12 +72,12 @@ #include #include #include +#include #include #include #include -#include #include #include @@ -161,7 +161,11 @@ s3c24xx_serial_dbg(const char *fmt, ...) /* we can support 3 uarts, but not always use them */ +#ifdef CONFIG_CPU_S3C2400 +#define NR_PORTS (2) +#else #define NR_PORTS (3) +#endif /* port irq numbers */ @@ -323,16 +327,6 @@ s3c24xx_serial_rx_chars(int irq, void *dev_id, struct pt_regs *regs) if (s3c24xx_serial_rx_fifocnt(ourport, ufstat) == 0) break; - if (tty->flip.count >= TTY_FLIPBUF_SIZE) { - if (tty->low_latency) - tty_flip_buffer_push(tty); - - /* - * If this failed then we will throw away the - * bytes but must do so to clear interrupts - */ - } - uerstat = rd_regl(port, S3C2410_UERSTAT); ch = rd_regb(port, S3C2410_URXH); @@ -782,11 +776,9 @@ static void s3c24xx_serial_set_termios(struct uart_port *port, if (ourport->baudclk != NULL && !IS_ERR(ourport->baudclk)) { clk_disable(ourport->baudclk); - clk_unuse(ourport->baudclk); ourport->baudclk = NULL; } - clk_use(clk); clk_enable(clk); ourport->clksrc = clksrc; @@ -1072,14 +1064,11 @@ static int s3c24xx_serial_init_port(struct s3c24xx_uart_port *ourport, dbg("resource %p (%lx..%lx)\n", res, res->start, res->end); port->mapbase = res->start; - port->membase = S3C24XX_VA_UART + (res->start - S3C2410_PA_UART); + port->membase = S3C24XX_VA_UART + (res->start - S3C24XX_PA_UART); port->irq = platform_get_irq(platdev, 0); ourport->clk = clk_get(&platdev->dev, "uart"); - if (ourport->clk != NULL && !IS_ERR(ourport->clk)) - clk_use(ourport->clk); - dbg("port: map=%08x, mem=%08x, irq=%d, clock=%ld\n", port->mapbase, port->membase, port->irq, port->uartclk);