• Home
  • Raw
  • Download

Lines Matching full:pdc

117 	bool			use_pdc_rx;	/* enable PDC receiver */
118 short pdc_rx_idx; /* current PDC RX buffer */
119 struct atmel_dma_buffer pdc_rx[2]; /* PDC receier */
122 bool use_pdc_tx; /* enable PDC transmitter */
123 struct atmel_dma_buffer pdc_tx; /* PDC transmitter */
554 /* disable PDC transmit */ in atmel_stop_tx()
593 /* re-enable PDC transmit */ in atmel_start_tx()
615 /* enable PDC controller */ in atmel_start_rx()
633 /* disable PDC receive */ in atmel_stop_rx()
1315 * PDC receive. Just schedule the tasklet and let it in atmel_handle_receive()
1456 struct atmel_dma_buffer *pdc = &atmel_port->pdc_tx; in atmel_release_tx_pdc() local
1459 pdc->dma_addr, in atmel_release_tx_pdc()
1460 pdc->dma_size, in atmel_release_tx_pdc()
1471 struct atmel_dma_buffer *pdc = &atmel_port->pdc_tx; in atmel_tx_pdc() local
1478 xmit->tail += pdc->ofs; in atmel_tx_pdc()
1481 port->icount.tx += pdc->ofs; in atmel_tx_pdc()
1482 pdc->ofs = 0; in atmel_tx_pdc()
1486 /* disable PDC transmit */ in atmel_tx_pdc()
1491 pdc->dma_addr, in atmel_tx_pdc()
1492 pdc->dma_size, in atmel_tx_pdc()
1496 pdc->ofs = count; in atmel_tx_pdc()
1499 pdc->dma_addr + xmit->tail); in atmel_tx_pdc()
1501 /* re-enable PDC transmit */ in atmel_tx_pdc()
1520 struct atmel_dma_buffer *pdc = &atmel_port->pdc_tx; in atmel_prepare_tx_pdc() local
1523 pdc->buf = xmit->buf; in atmel_prepare_tx_pdc()
1524 pdc->dma_addr = dma_map_single(port->dev, in atmel_prepare_tx_pdc()
1525 pdc->buf, in atmel_prepare_tx_pdc()
1528 pdc->dma_size = UART_XMIT_SIZE; in atmel_prepare_tx_pdc()
1529 pdc->ofs = 0; in atmel_prepare_tx_pdc()
1608 struct atmel_dma_buffer *pdc = &atmel_port->pdc_rx[i]; in atmel_release_rx_pdc() local
1611 pdc->dma_addr, in atmel_release_rx_pdc()
1612 pdc->dma_size, in atmel_release_rx_pdc()
1614 kfree(pdc->buf); in atmel_release_rx_pdc()
1622 struct atmel_dma_buffer *pdc; in atmel_rx_from_pdc() local
1632 pdc = &atmel_port->pdc_rx[rx_idx]; in atmel_rx_from_pdc()
1633 head = atmel_uart_readl(port, ATMEL_PDC_RPR) - pdc->dma_addr; in atmel_rx_from_pdc()
1634 tail = pdc->ofs; in atmel_rx_from_pdc()
1636 /* If the PDC has switched buffers, RPR won't contain in atmel_rx_from_pdc()
1646 head = min(head, pdc->dma_size); in atmel_rx_from_pdc()
1649 dma_sync_single_for_cpu(port->dev, pdc->dma_addr, in atmel_rx_from_pdc()
1650 pdc->dma_size, DMA_FROM_DEVICE); in atmel_rx_from_pdc()
1660 tty_insert_flip_string(tport, pdc->buf + pdc->ofs, in atmel_rx_from_pdc()
1663 dma_sync_single_for_device(port->dev, pdc->dma_addr, in atmel_rx_from_pdc()
1664 pdc->dma_size, DMA_FROM_DEVICE); in atmel_rx_from_pdc()
1667 pdc->ofs = head; in atmel_rx_from_pdc()
1674 if (head >= pdc->dma_size) { in atmel_rx_from_pdc()
1675 pdc->ofs = 0; in atmel_rx_from_pdc()
1676 atmel_uart_writel(port, ATMEL_PDC_RNPR, pdc->dma_addr); in atmel_rx_from_pdc()
1677 atmel_uart_writel(port, ATMEL_PDC_RNCR, pdc->dma_size); in atmel_rx_from_pdc()
1682 } while (head >= pdc->dma_size); in atmel_rx_from_pdc()
1702 struct atmel_dma_buffer *pdc = &atmel_port->pdc_rx[i]; in atmel_prepare_rx_pdc() local
1704 pdc->buf = kmalloc(PDC_BUFFER_SIZE, GFP_KERNEL); in atmel_prepare_rx_pdc()
1705 if (pdc->buf == NULL) { in atmel_prepare_rx_pdc()
1716 pdc->dma_addr = dma_map_single(port->dev, in atmel_prepare_rx_pdc()
1717 pdc->buf, in atmel_prepare_rx_pdc()
1720 pdc->dma_size = PDC_BUFFER_SIZE; in atmel_prepare_rx_pdc()
1721 pdc->ofs = 0; in atmel_prepare_rx_pdc()
1768 /* DMA/PDC usage specification */ in atmel_init_property()
2004 /* enable PDC controller */ in atmel_startup()
2585 /* Store PDC transmit status and disable it */ in atmel_console_write()
2603 /* Restore PDC transmit status */ in atmel_console_write()