lkml.org 
[lkml]   [2008]   [Feb]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH -mm v4 6/9] atmel_serial: Split the interrupt handler
Hi
> Haavard
>
> diff --git a/drivers/serial/atmel_serial.c b/drivers/serial/atmel_serial.c
> index 477950f..c61fcc3 100644
> --- a/drivers/serial/atmel_serial.c
> +++ b/drivers/serial/atmel_serial.c
> @@ -337,9 +337,12 @@ atmel_buffer_rx_char(struct uart_port *port, unsigned int status,
> struct circ_buf *ring = &atmel_port->rx_ring;
> struct atmel_uart_char *c;
>
> - if (!CIRC_SPACE(ring->head, ring->tail, ATMEL_SERIAL_RINGSIZE))
> + if (!CIRC_SPACE(ring->head, ring->tail, ATMEL_SERIAL_RINGSIZE)) {
> + dev_err(port->dev, "RX ring buffer full, dropping data\n");
> +
> /* Buffer overflow, ignore char */
> return;
> + }
>
> c = &((struct atmel_uart_char *)ring->buf)[ring->head];
> c->status = status;
>
>

I have already tried that but I have never seen the buffer full. So
tomorrow I can do other
tests with the serial device. I think the the atmel_interrupt handler
must check the
pass_counter before return IRQ_HANDLED.

Regards Michael




\
 
 \ /
  Last update: 2008-02-04 20:05    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site