]> git.ipfire.org Git - thirdparty/kernel/stable.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)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 2 Jan 2026 11:57:07 +0000 (12:57 +0100)
commit9285d04830639e4bfe05a94fef50296014f9bffe
treee25a6cb5b5cbd1329ff5a346e475c3dfc8aadf53
parent4bb9164e8f21ecb3372dfa051450bdcc1490dbaa
mmc: sdhci-msm: Avoid early clock doubling during HS400 transition

commit b1f856b1727c2eaa4be2c6d7cd7a8ed052bbeb87 upstream.

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>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/mmc/host/sdhci-msm.c