Lines Matching refs:t

63 	int (*txrx_bufs)(struct spi_device *spi, struct spi_transfer *t);
230 static int au1550_spi_setupxfer(struct spi_device *spi, struct spi_transfer *t) in au1550_spi_setupxfer() argument
236 if (t) { in au1550_spi_setupxfer()
237 bpw = t->bits_per_word; in au1550_spi_setupxfer()
238 hz = t->speed_hz; in au1550_spi_setupxfer()
314 static int au1550_spi_dma_txrxb(struct spi_device *spi, struct spi_transfer *t) in au1550_spi_dma_txrxb() argument
321 hw->len = t->len; in au1550_spi_dma_txrxb()
325 hw->tx = t->tx_buf; in au1550_spi_dma_txrxb()
326 hw->rx = t->rx_buf; in au1550_spi_dma_txrxb()
327 dma_tx_addr = t->tx_dma; in au1550_spi_dma_txrxb()
328 dma_rx_addr = t->rx_dma; in au1550_spi_dma_txrxb()
338 if (t->tx_buf) { in au1550_spi_dma_txrxb()
339 if (t->tx_dma == 0) { /* if DMA_ADDR_INVALID, map it */ in au1550_spi_dma_txrxb()
341 (void *)t->tx_buf, in au1550_spi_dma_txrxb()
342 t->len, DMA_TO_DEVICE); in au1550_spi_dma_txrxb()
348 if (t->rx_buf) { in au1550_spi_dma_txrxb()
349 if (t->rx_dma == 0) { /* if DMA_ADDR_INVALID, map it */ in au1550_spi_dma_txrxb()
351 (void *)t->rx_buf, in au1550_spi_dma_txrxb()
352 t->len, DMA_FROM_DEVICE); in au1550_spi_dma_txrxb()
357 if (t->len > hw->dma_rx_tmpbuf_size) { in au1550_spi_dma_txrxb()
361 ret = au1550_spi_dma_rxtmp_alloc(hw, max(t->len, in au1550_spi_dma_txrxb()
369 t->len, DMA_FROM_DEVICE); in au1550_spi_dma_txrxb()
372 if (!t->tx_buf) { in au1550_spi_dma_txrxb()
374 t->len, DMA_BIDIRECTIONAL); in au1550_spi_dma_txrxb()
380 t->len, DDMA_FLAGS_IE); in au1550_spi_dma_txrxb()
385 t->len, DDMA_FLAGS_IE); in au1550_spi_dma_txrxb()
405 if (!t->rx_buf) { in au1550_spi_dma_txrxb()
407 dma_sync_single_for_cpu(hw->dev, dma_rx_addr, t->len, in au1550_spi_dma_txrxb()
411 if (t->rx_buf && t->rx_dma == 0 ) in au1550_spi_dma_txrxb()
412 dma_unmap_single(hw->dev, dma_rx_addr, t->len, in au1550_spi_dma_txrxb()
414 if (t->tx_buf && t->tx_dma == 0 ) in au1550_spi_dma_txrxb()
415 dma_unmap_single(hw->dev, dma_tx_addr, t->len, in au1550_spi_dma_txrxb()
512 static int au1550_spi_pio_txrxb(struct spi_device *spi, struct spi_transfer *t) in au1550_spi_pio_txrxb() argument
517 hw->tx = t->tx_buf; in au1550_spi_pio_txrxb()
518 hw->rx = t->rx_buf; in au1550_spi_pio_txrxb()
519 hw->len = t->len; in au1550_spi_pio_txrxb()
645 static int au1550_spi_txrx_bufs(struct spi_device *spi, struct spi_transfer *t) in au1550_spi_txrx_bufs() argument
648 return hw->txrx_bufs(spi, t); in au1550_spi_txrx_bufs()