Lines Matching refs:scratch
98 /* "scratch" is per-{command,block} data exchanged with the card */
99 struct scratch {
123 struct scratch *data;
239 * be stored in the scratch buffer. It's somewhere after the
413 struct scratch *data = host->data;
526 struct scratch *scratch = host->data;
538 scratch->data_token = SPI_TOKEN_MULTI_WRITE;
540 scratch->data_token = SPI_TOKEN_SINGLE;
541 t->tx_buf = &scratch->data_token;
559 t->tx_buf = &scratch->crc_val;
562 t->rx_buf = &scratch->crc_val;
583 t->len = (direction == DMA_TO_DEVICE) ? sizeof(scratch->status) : 1;
585 t->rx_buf = scratch->status;
609 struct scratch *scratch = host->data;
613 scratch->crc_val = cpu_to_be16(crc_itu_t(0, t->tx_buf, t->len));
633 pattern = get_unaligned_be32(scratch->status);
664 scratch->status[0], status);
673 for (i = 4; i < sizeof(scratch->status); i++) {
675 if (scratch->status[i] & 0x01)
703 struct scratch *scratch = host->data;
713 status = scratch->status[0];
751 cp = (u8 *) &scratch->crc_val;
762 be16_to_cpus(&scratch->crc_val);
763 if (scratch->crc_val != crc) {
766 scratch->crc_val, crc, t->len);
866 struct scratch *scratch = host->data;
868 const unsigned statlen = sizeof(scratch->status);
881 memset(scratch->status, 0xff, statlen);
882 scratch->status[0] = SPI_TOKEN_STOP_TRAN;
899 if (scratch->status[tmp] != 0)