Govindraj >From: Govindraj R <govindraj.raja@xxxxxx> > >This patch adds support for OMAP3430-HIGH SPEED UART Controller. > >It currently adds support for the following features. > > 1. Supports Interrupt Mode for all three UARTs on SDP/ZOOM2. > 2. Supports DMA Mode for all three UARTs on SDP/ZOOM2. > 3. Supports Hardware flow control (CTS/RTS) on SDP/ZOOM2. > 4. Supports 3.6Mbps baudrate on SDP/ZOOM2. > 5. Debug Console support on all UARTs on SDP/ZOOM2. > 6. Support for quad uart on ZOOM2 board. What about UART3 supporting IRDA and CIR modes? Is that planned to be added? > >+ >+static unsigned int check_modem_status(struct uart_omap_port *up) What is the use case for modem_status? >+{ >+ >+/* >+ * This handles the interrupt from one port. >+ */ >+static inline irqreturn_t serial_omap_irq(int irq, void *dev_id) >+{ >+ struct uart_omap_port *up = dev_id; >+ unsigned int iir, lsr; >+ >+ iir = serial_in(up, UART_IIR); >+ if (iir & UART_IIR_NO_INT) >+ return IRQ_NONE; >+ lsr = serial_in(up, UART_LSR); >+ if ((iir & 0x4) && up->use_dma) { >+ up->ier &= ~UART_IER_RDI; >+ serial_out(up, UART_IER, up->ier); >+ serial_omap_start_rxdma(up); >+ } else if (lsr & UART_LSR_DR) >+ receive_chars(up, &lsr); >+ check_modem_status(up); >+ if ((lsr & UART_LSR_THRE) && (iir & 0x2)) >+ transmit_chars(up); >+ up_activity = jiffies; >+ >+ return IRQ_HANDLED; >+} >+ Query: >+static void serial_omap_rx_timeout(unsigned long uart_no) >+{ >+ struct uart_omap_port *up = ui[uart_no - 1]; >+ unsigned int curr_dma_pos; >+ curr_dma_pos = omap_readl(OMAP34XX_DMA4_BASE + >+ OMAP_DMA4_CDAC(up->uart_dma.rx_dma_channel)); >+ if ((curr_dma_pos == up->uart_dma.prev_rx_dma_pos) || >+ (curr_dma_pos == 0)) { >+ if (jiffies_to_msecs(jiffies - up_activity) < 10000) { >+ mod_timer(&up->uart_dma.rx_timer, jiffies + >+ usecs_to_jiffies(up->uart_dma.rx_timeout)); Is this a 10 second timeout? Is this acceptable way? This has to be done in conjunction with the inactivity timer in mach-omap2/serial.c >+ } else { >+ serial_omap_stop_rxdma(up); >+ up->ier |= UART_IER_RDI; >+ serial_out(up, UART_IER, up->ier); >+ } >+ >+ return; >+ } else { >+ unsigned int curr_transmitted_size = curr_dma_pos - >+ up->uart_dma.prev_rx_dma_pos; >+ up->port.icount.rx += curr_transmitted_size; >+ tty_insert_flip_string(up->port.info->port.tty, >+ up->uart_dma.rx_buf + >+ (up->uart_dma.prev_rx_dma_pos - >+ up->uart_dma.rx_buf_dma_phys), >+ curr_transmitted_size); >+ tty_flip_buffer_push(up->port.info->port.tty); >+ up->uart_dma.prev_rx_dma_pos = curr_dma_pos; >+ if (up->uart_dma.rx_buf_size + >+ up->uart_dma.rx_buf_dma_phys == curr_dma_pos) >+ serial_omap_start_rxdma(up); >+ else >+ mod_timer(&up->uart_dma.rx_timer, jiffies + >+ usecs_to_jiffies(up->uart_dma.rx_timeout)); >+ up_activity = jiffies; >+ >+ } -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html