mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v2 0/2] mmc: core: sdio: fix UHS init with fixed 1.8V vqmmc
@ 2026-10-27 12:24 Deomid rojer Ryabkov
  2026-10-27 12:24 ` [PATCH v2 1/2] mmc: core: sdio: retry without UHS if UHS init fails Deomid rojer Ryabkov
  2026-10-27 12:24 ` [PATCH v2 2/2] mmc: core: sdio: skip CMD11 if signalling is already 1.8V Deomid rojer Ryabkov
  0 siblings, 2 replies; 3+ messages in thread
From: Deomid rojer Ryabkov @ 2026-10-27 12:24 UTC (permalink / raw)
  To: ulfh; +Cc: linux-mmc, linux-kernel, shawn.lin, llj, Deomid rojer Ryabkov

The Realtek RTL8822CS SDIO Wi-Fi module on the FriendlyElec NanoPi R2S
Plus (fixed 1.8V vqmmc) reports S18A = 1 in its R4 response although the
bus is already at 1.8V, contrary to the SDIO Simplified Specification
3.00, section 3.1.2. CMD11 then times out and the module ends up at
50 MHz high-speed instead of SDR104. The SWT6621S behaves the same way
and, without patch 2, doesn't come up at all.

Patch 1 makes SDIO init fall back to high-speed mode if UHS init fails
(e.g. tuning), instead of failing the card altogether.

Patch 2 skips CMD11 when the host is already at 1.8V.

Tested on a NanoPi R2S Plus (OpenWrt 25.12, Linux 6.12.112 with these
patches; applies to mainline as of 2026-10-22): SDR104 at 150 MHz; iperf
as a 5 GHz VHT80 station goes from 70/29 to 123/125 Mbit/s (rx/tx). eMMC
(HS200) and SD card on the same SoC are unaffected. Longjian tested
patch 2 with an SWT6621S.

The device tree part for the R2S Plus is sent separately to
linux-rockchip.

Changes in v2:
- 1/2: the existing CCCR fallback resets the card, it doesn't
  power-cycle it (Shawn).
- 2/2: note in the commit message that this relies on the fixed 1.8V
  supply being described as vqmmc-supply (Shawn).
- Dropped "2/2 alt", the alternative to 2/2 that kept sending CMD11.
- Collected Reviewed-by (Shawn) and Tested-by (Longjian, 2/2; his
  reply didn't reach the list, it was HTML).

v1: https://lore.kernel.org/linux-mmc/20261023232813.2983368-1-rojer@rojer.me/

Deomid rojer Ryabkov (2):
  mmc: core: sdio: retry without UHS if UHS init fails
  mmc: core: sdio: skip CMD11 if signalling is already 1.8V

 drivers/mmc/core/sdio.c | 16 ++++++++++++----
 1 file changed, 12 insertions(+), 4 deletions(-)


base-commit: 734bef548a96e8774d6eef5dfa2026c6edc4e80b
-- 
2.53.0


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

end of thread, other threads:[~2026-10-27 12:24 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-27 12:24 [PATCH v2 0/2] mmc: core: sdio: fix UHS init with fixed 1.8V vqmmc Deomid rojer Ryabkov
2026-10-27 12:24 ` [PATCH v2 1/2] mmc: core: sdio: retry without UHS if UHS init fails Deomid rojer Ryabkov
2026-10-27 12:24 ` [PATCH v2 2/2] mmc: core: sdio: skip CMD11 if signalling is already 1.8V Deomid rojer Ryabkov

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

all inboxes | Powered by JetHome®