Lines Matching refs:scratch
97 /* "scratch" is per-{command,block} data exchanged with the card */
98 struct scratch {
122 struct scratch *data;
227 * be stored in the scratch buffer. It's somewhere after the
402 struct scratch *data = host->data;
512 struct scratch *scratch = host->data;
524 scratch->data_token = SPI_TOKEN_MULTI_WRITE;
526 scratch->data_token = SPI_TOKEN_SINGLE;
527 t->tx_buf = &scratch->data_token;
545 t->tx_buf = &scratch->crc_val;
548 t->rx_buf = &scratch->crc_val;
569 t->len = write ? sizeof(scratch->status) : 1;
571 t->rx_buf = scratch->status;
595 struct scratch *scratch = host->data;
599 scratch->crc_val = cpu_to_be16(crc_itu_t(0, t->tx_buf, t->len));
619 pattern = get_unaligned_be32(scratch->status);
650 scratch->status[0], status);
659 for (i = 4; i < sizeof(scratch->status); i++) {
661 if (scratch->status[i] & 0x01)
689 struct scratch *scratch = host->data;
699 status = scratch->status[0];
737 cp = (u8 *) &scratch->crc_val;
748 be16_to_cpus(&scratch->crc_val);
749 if (scratch->crc_val != crc) {
752 scratch->crc_val, crc, t->len);
849 struct scratch *scratch = host->data;
851 const unsigned statlen = sizeof(scratch->status);
864 memset(scratch->status, 0xff, statlen);
865 scratch->status[0] = SPI_TOKEN_STOP_TRAN;
882 if (scratch->status[tmp] != 0)