]> git.ipfire.org Git - thirdparty/linux.git/commit
mmc: sdhci-msm: Avoid early clock doubling during HS400 transition
authorSarthak Garg <sarthak.garg@oss.qualcomm.com>
Fri, 14 Nov 2025 08:28:24 +0000 (13:58 +0530)
committerUlf Hansson <ulf.hansson@linaro.org>
Tue, 25 Nov 2025 12:39:46 +0000 (13:39 +0100)
commitb1f856b1727c2eaa4be2c6d7cd7a8ed052bbeb87
tree5cf2f741005d2446c988fa33fd921d4dac0334c5
parent8a4a16f86edc10e162f0e305bdfa8f1f9c522551
mmc: sdhci-msm: Avoid early clock doubling during HS400 transition

According to the hardware programming guide, the clock frequency must
remain below 52MHz during the transition to HS400 mode.

However,in the current implementation, the timing is set to HS400 (a
DDR mode) before adjusting the clock. This causes the clock to double
prematurely to 104MHz during the transition phase, violating the
specification and potentially resulting in CRC errors or CMD timeouts.

This change ensures that clock doubling is avoided during intermediate
transitions and is applied only when the card requires a 200MHz clock
for HS400 operation.

Signed-off-by: Sarthak Garg <sarthak.garg@oss.qualcomm.com>
Reviewed-by: Bjorn Andersson <andersson@kernel.org>
Acked-by: Adrian Hunter <adrian.hunter@intel.com>
Cc: stable@vger.kernel.org
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
drivers/mmc/host/sdhci-msm.c