mmc: octeontx2: track & apply CMD6 bus changes ASAP
commit e91f1d645fcd073223289f141ef4369150fae118 from git@git.assembla.com:cavium/WindRiver.linux.git When mmc/core issued CMD6 to change bus width, timing and encoding style, we must apply the change to our hardware immediately. Previous code applied it eventually, but meanwhile mmc/core code had been polling status with CMD13 under the old protocol, which may have been causing HS400 transitions to fail. To apply the change immediately, at IRQ-time, the host pointer is set on every outgoing request, so IRQ handler can find context (the associated cvm_mmc_slot) for a successfully executed CMD6, and the MIO_EMM_SWITCH value it should apply, to bring the host hardware & target card into alignment. CMD6 can potentially set/clear individual bits of ext_csd, which would require caching the ext_csd entries for the 3 bytes we track, to reconstruct the meaning. But fortunately mmc/core only issues a full-byte assignment (action=3) for the power/width/timing properties we mirror. Should this change, more work may be needed here. Change-Id: I13df44e96d61a071b73f1d3f014ff0276ba51135 Signed-off-by:Peter Swain <pswain@marvell.com> Signed-off-by:
Sujeet Baranwal <sbaranwal@marvell.com> Reviewed-on: https://sj1git1.cavium.com/8546 Reviewed-by:
Sunil Kovvuri Goutham <Sunil.Goutham@cavium.com> Tested-by:
Sunil Kovvuri Goutham <Sunil.Goutham@cavium.com> Reviewed-on: https://sj1git1.cavium.com/c/IP/SW/kernel/linux/+/26909 Reviewed-by:
Chandrakala Chavva <cchavva@marvell.com> [RQ: remove unused var flags.] Signed-off-by:
Ruiqiang Hao <Ruiqiang.Hao@windriver.com>
Loading
Please register or sign in to comment