public inbox for linux-mmc@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/2] mmc: litex_mmc: Set mandatory idle clocks before CMD0
@ 2026-04-26 11:20 Inochi Amaoto
  2026-04-26 11:20 ` [PATCH v3 1/2] mmc: litex_mmc: Move litex_mmc_setclk() to bottom for reuse Inochi Amaoto
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Inochi Amaoto @ 2026-04-26 11:20 UTC (permalink / raw)
  To: Ulf Hansson, Karol Gugala, Mateusz Holenko, Gabriel Somlo,
	Joel Stanley, Paul Mackerras, Maciej Dudek, Andy Shevchenko
  Cc: Inochi Amaoto, linux-mmc, linux-kernel, Yixun Lan, Longbin Li

The litex_mmc driver assumes the card is already probed in the BIOS
and skip the phy initialization. This will cause the command fail
like the following when the old card is unplugged and then insert
a new card:

[   62.923593] litex-mmc f0004000.mmc: Command (cmd 8) error, status -110
[   62.949717] litex-mmc f0004000.mmc: Command (cmd 55) error, status -110
[   62.976606] litex-mmc f0004000.mmc: Command (cmd 55) error, status -110
[   63.002516] litex-mmc f0004000.mmc: Command (cmd 55) error, status -110
[   63.028442] litex-mmc f0004000.mmc: Command (cmd 55) error, status -110

Add required clock settings and initialization for the CMD 0, so it can
probe the new card.

Changed from v2:
- https://lore.kernel.org/linux-mmc/20260424013615.470325-1-inochiama@gmail.com/
1. Remove the added function forward reference and add a new patch
   for moving litex_mmc_setclk() function

Change from v1:
- https://lore.kernel.org/linux-mmc/20260421025052.755471-1-inochiama@gmail.com/
1. use fsleep to replace udelay

Inochi Amaoto (2):
  mmc: litex_mmc: Move litex_mmc_setclk() to bottom for reuse
  mmc: litex_mmc: Set mandatory idle clocks before CMD0

 drivers/mmc/host/litex_mmc.c | 37 ++++++++++++++++++++++--------------
 1 file changed, 23 insertions(+), 14 deletions(-)

--
2.54.0


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2026-04-26 15:59 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-26 11:20 [PATCH v3 0/2] mmc: litex_mmc: Set mandatory idle clocks before CMD0 Inochi Amaoto
2026-04-26 11:20 ` [PATCH v3 1/2] mmc: litex_mmc: Move litex_mmc_setclk() to bottom for reuse Inochi Amaoto
2026-04-26 11:20 ` [PATCH v3 2/2] mmc: litex_mmc: Set mandatory idle clocks before CMD0 Inochi Amaoto
2026-04-26 15:59 ` [PATCH v3 0/2] " Gabriel L. Somlo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox