Lines Matching refs:t
115 struct spi_transfer token, t, crc, early_status; member
220 u8 *end = cp + host->t.len; in mmc_spi_response_get()
406 struct spi_transfer *t; in mmc_spi_command_send() local
483 t = &host->t; in mmc_spi_command_send()
484 memset(t, 0, sizeof(*t)); in mmc_spi_command_send()
485 t->tx_buf = t->rx_buf = data->status; in mmc_spi_command_send()
486 t->len = cp - data->status; in mmc_spi_command_send()
487 t->cs_change = 1; in mmc_spi_command_send()
488 spi_message_add_tail(t, &host->m); in mmc_spi_command_send()
515 struct spi_transfer *t; in mmc_spi_setup_data_message() local
524 t = &host->token; in mmc_spi_setup_data_message()
525 memset(t, 0, sizeof(*t)); in mmc_spi_setup_data_message()
526 t->len = 1; in mmc_spi_setup_data_message()
531 t->tx_buf = &scratch->data_token; in mmc_spi_setup_data_message()
532 spi_message_add_tail(t, &host->m); in mmc_spi_setup_data_message()
538 t = &host->t; in mmc_spi_setup_data_message()
539 memset(t, 0, sizeof(*t)); in mmc_spi_setup_data_message()
540 t->tx_buf = host->ones; in mmc_spi_setup_data_message()
542 spi_message_add_tail(t, &host->m); in mmc_spi_setup_data_message()
544 t = &host->crc; in mmc_spi_setup_data_message()
545 memset(t, 0, sizeof(*t)); in mmc_spi_setup_data_message()
546 t->len = 2; in mmc_spi_setup_data_message()
549 t->tx_buf = &scratch->crc_val; in mmc_spi_setup_data_message()
551 t->tx_buf = host->ones; in mmc_spi_setup_data_message()
552 t->rx_buf = &scratch->crc_val; in mmc_spi_setup_data_message()
554 spi_message_add_tail(t, &host->m); in mmc_spi_setup_data_message()
571 t = &host->early_status; in mmc_spi_setup_data_message()
572 memset(t, 0, sizeof(*t)); in mmc_spi_setup_data_message()
573 t->len = (direction == DMA_TO_DEVICE) ? sizeof(scratch->status) : 1; in mmc_spi_setup_data_message()
574 t->tx_buf = host->ones; in mmc_spi_setup_data_message()
575 t->rx_buf = scratch->status; in mmc_spi_setup_data_message()
576 t->cs_change = 1; in mmc_spi_setup_data_message()
577 spi_message_add_tail(t, &host->m); in mmc_spi_setup_data_message()
594 mmc_spi_writeblock(struct mmc_spi_host *host, struct spi_transfer *t, in mmc_spi_writeblock() argument
603 scratch->crc_val = cpu_to_be16(crc_itu_t(0, t->tx_buf, t->len)); in mmc_spi_writeblock()
658 t->tx_buf += t->len; in mmc_spi_writeblock()
688 mmc_spi_readblock(struct mmc_spi_host *host, struct spi_transfer *t, in mmc_spi_readblock() argument
732 u8 *cp = t->rx_buf; in mmc_spi_readblock()
736 for (len = t->len; len; len--) { in mmc_spi_readblock()
750 u16 crc = crc_itu_t(0, t->rx_buf, t->len); in mmc_spi_readblock()
756 scratch->crc_val, crc, t->len); in mmc_spi_readblock()
761 t->rx_buf += t->len; in mmc_spi_readblock()
776 struct spi_transfer *t; in mmc_spi_data_do() local
786 t = &host->t; in mmc_spi_data_do()
788 if (t->speed_hz) in mmc_spi_data_do()
789 clock_rate = t->speed_hz; in mmc_spi_data_do()
808 t->tx_buf = kmap_addr + sg->offset; in mmc_spi_data_do()
810 t->rx_buf = kmap_addr + sg->offset; in mmc_spi_data_do()
814 t->len = min(length, blk_size); in mmc_spi_data_do()
816 dev_dbg(&spi->dev, " %s block, %d bytes\n", write_or_read, t->len); in mmc_spi_data_do()
819 status = mmc_spi_writeblock(host, t, timeout); in mmc_spi_data_do()
821 status = mmc_spi_readblock(host, t, timeout); in mmc_spi_data_do()
825 data->bytes_xfered += t->len; in mmc_spi_data_do()
826 length -= t->len; in mmc_spi_data_do()