Lines Matching refs:t

135 	struct spi_transfer	token, t, crc, early_status;  member
266 u8 *end = cp + host->t.len; in mmc_spi_response_get()
452 struct spi_transfer *t; in mmc_spi_command_send() local
529 t = &host->t; in mmc_spi_command_send()
530 memset(t, 0, sizeof(*t)); in mmc_spi_command_send()
531 t->tx_buf = t->rx_buf = data->status; in mmc_spi_command_send()
532 t->tx_dma = t->rx_dma = host->data_dma; in mmc_spi_command_send()
533 t->len = cp - data->status; in mmc_spi_command_send()
534 t->cs_change = 1; in mmc_spi_command_send()
535 spi_message_add_tail(t, &host->m); in mmc_spi_command_send()
576 struct spi_transfer *t; in mmc_spi_setup_data_message() local
588 t = &host->token; in mmc_spi_setup_data_message()
589 memset(t, 0, sizeof(*t)); in mmc_spi_setup_data_message()
590 t->len = 1; in mmc_spi_setup_data_message()
595 t->tx_buf = &scratch->data_token; in mmc_spi_setup_data_message()
597 t->tx_dma = dma + offsetof(struct scratch, data_token); in mmc_spi_setup_data_message()
598 spi_message_add_tail(t, &host->m); in mmc_spi_setup_data_message()
604 t = &host->t; in mmc_spi_setup_data_message()
605 memset(t, 0, sizeof(*t)); in mmc_spi_setup_data_message()
606 t->tx_buf = host->ones; in mmc_spi_setup_data_message()
607 t->tx_dma = host->ones_dma; in mmc_spi_setup_data_message()
609 spi_message_add_tail(t, &host->m); in mmc_spi_setup_data_message()
611 t = &host->crc; in mmc_spi_setup_data_message()
612 memset(t, 0, sizeof(*t)); in mmc_spi_setup_data_message()
613 t->len = 2; in mmc_spi_setup_data_message()
616 t->tx_buf = &scratch->crc_val; in mmc_spi_setup_data_message()
618 t->tx_dma = dma + offsetof(struct scratch, crc_val); in mmc_spi_setup_data_message()
620 t->tx_buf = host->ones; in mmc_spi_setup_data_message()
621 t->tx_dma = host->ones_dma; in mmc_spi_setup_data_message()
622 t->rx_buf = &scratch->crc_val; in mmc_spi_setup_data_message()
624 t->rx_dma = dma + offsetof(struct scratch, crc_val); in mmc_spi_setup_data_message()
626 spi_message_add_tail(t, &host->m); in mmc_spi_setup_data_message()
643 t = &host->early_status; in mmc_spi_setup_data_message()
644 memset(t, 0, sizeof(*t)); in mmc_spi_setup_data_message()
645 t->len = (direction == DMA_TO_DEVICE) in mmc_spi_setup_data_message()
648 t->tx_buf = host->ones; in mmc_spi_setup_data_message()
649 t->tx_dma = host->ones_dma; in mmc_spi_setup_data_message()
650 t->rx_buf = scratch->status; in mmc_spi_setup_data_message()
652 t->rx_dma = dma + offsetof(struct scratch, status); in mmc_spi_setup_data_message()
653 t->cs_change = 1; in mmc_spi_setup_data_message()
654 spi_message_add_tail(t, &host->m); in mmc_spi_setup_data_message()
671 mmc_spi_writeblock(struct mmc_spi_host *host, struct spi_transfer *t, in mmc_spi_writeblock() argument
681 crc_itu_t(0, t->tx_buf, t->len)); in mmc_spi_writeblock()
746 t->tx_buf += t->len; in mmc_spi_writeblock()
748 t->tx_dma += t->len; in mmc_spi_writeblock()
778 mmc_spi_readblock(struct mmc_spi_host *host, struct spi_transfer *t, in mmc_spi_readblock() argument
817 t->rx_dma, t->len, in mmc_spi_readblock()
828 t->rx_dma, t->len, in mmc_spi_readblock()
836 u8 *cp = t->rx_buf; in mmc_spi_readblock()
840 for (len = t->len; len; len--) { in mmc_spi_readblock()
854 u16 crc = crc_itu_t(0, t->rx_buf, t->len); in mmc_spi_readblock()
860 scratch->crc_val, crc, t->len); in mmc_spi_readblock()
865 t->rx_buf += t->len; in mmc_spi_readblock()
867 t->rx_dma += t->len; in mmc_spi_readblock()
883 struct spi_transfer *t; in mmc_spi_data_do() local
896 t = &host->t; in mmc_spi_data_do()
898 if (t->speed_hz) in mmc_spi_data_do()
899 clock_rate = t->speed_hz; in mmc_spi_data_do()
929 t->tx_dma = dma_addr + sg->offset; in mmc_spi_data_do()
931 t->rx_dma = dma_addr + sg->offset; in mmc_spi_data_do()
937 t->tx_buf = kmap_addr + sg->offset; in mmc_spi_data_do()
939 t->rx_buf = kmap_addr + sg->offset; in mmc_spi_data_do()
943 t->len = min(length, blk_size); in mmc_spi_data_do()
950 t->len); in mmc_spi_data_do()
953 status = mmc_spi_writeblock(host, t, timeout); in mmc_spi_data_do()
955 status = mmc_spi_readblock(host, t, timeout); in mmc_spi_data_do()
959 data->bytes_xfered += t->len; in mmc_spi_data_do()
960 length -= t->len; in mmc_spi_data_do()