Re: [PATCH 2/4] Blackfin: Serial driver for Blackfin arch on 2.6.18

From: Randy.Dunlap
Date: Thu Sep 21 2006 - 12:07:05 EST


On Thu, 21 Sep 2006 17:57:03 +0800 Luke Yang wrote:

> Great thanks. Here is the new patch:
>
> drivers/serial/Kconfig | 44 ++
> drivers/serial/Makefile | 1
> drivers/serial/bfin_5xx.c | 906 ++++++++++++++++++++++++++++++++++++++++++++
> include/linux/serial_core.h | 3
> 4 files changed, 954 insertions(+)
>

> +#ifdef CONFIG_SERIAL_BFIN_DMA
> +static void bfin_serial_dma_tx_chars(struct bfin_serial_port *uart)
> +{
> + struct circ_buf *xmit = &uart->port.info->xmit;
> + unsigned short ier;
> + int flags = 0;
> +
> + if (!uart->tx_done)
> + return;
> +
> + uart->tx_done = 0;
> +
> + if (uart->port.x_char) {
> + UART_PUT_CHAR(uart, uart->port.x_char);
> + uart->port.icount.tx++;
> + uart->port.x_char = 0;
> + uart->tx_done = 1;
> + return;
> + }
> + /*
> + * Check the modem control lines before
> + * transmitting anything.
> + */
> + bfin_serial_mctrl_check(uart);
> +
> + if (uart_circ_empty(xmit) || uart_tx_stopped(&uart->port)) {
> + bfin_serial_stop_tx(&uart->port);
> + uart->tx_done = 1;
> + return;
> + }
> +
> + local_irq_save(flags);
> + uart->tx_count = CIRC_CNT(xmit->head, xmit->tail, UART_XMIT_SIZE);
> + if (uart->tx_count > (UART_XMIT_SIZE - xmit->tail))
> + uart->tx_count = UART_XMIT_SIZE - xmit->tail;

The line above still needs to be indented one more tab stop.
Otherwise looks OK to me.

---
~Randy
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/