Re: CM23: Reliable Write Request / Forced Programming Bits

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I looked over the main use in the mmc block queue:
This hardcoded (1 << 31), (1 << 29) ...

if ((md->flags & MMC_BLK_CMD23) && mmc_op_multi(brq->cmd.opcode) &&
(do_rel_wr || !(card->quirks & MMC_QUIRK_BLK_NO_CMD23) ||
do_data_tag)) {
brq->sbc.opcode = MMC_SET_BLOCK_COUNT;
brq->sbc.arg = brq->data.blocks |
(do_rel_wr ? (1 << 31) : 0) |
(do_data_tag ? (1 << 29) : 0);
brq->sbc.flags = MMC_RSP_R1 | MMC_CMD_AC;
brq->mrq.sbc = &brq->sbc;
}

https://github.com/torvalds/linux/blob/master/drivers/mmc/core/block.c#L1629

I think this clears things up.
=> I need to adapt my mmc_test sample code and simply set the request member:

struct mmc_command sbc = {};
mrq->sbc = &sbc;

before calling mmc_test_prepare_sbc. Then the sbc opcode will be initialized.
And if the MMC host and card supports CMD23 the host driver will
execute the previously set mrq->sbc and disable auto CMD23 for this
request.
Am I right?



[Index of Archives]     [Linux Memonry Technology]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux