Re: [PATCH] mmc: rtsx_usb_sdmmc: start card power-up at 3.3V
From: Ulf Hansson
Date: Thu Sep 10 2026 - 12:26:35 EST
On Mon, Aug 24, 2026 at 10:39 PM Sean Rhodes <sean@starlabs.systems> wrote:
>
> A UHS session can leave the SD pads and SD18 regulator configured for
> 1.8V. The power-off path disables card power and suspends the regulator,
> but does not restore their voltage selection.
>
> On the next power-up, this stale state remains until after the MMC core
> requests its initial signal voltage. Restore the SD pads and SD18 regulator
> to 3.3V before enabling card power, as the old rts5139 driver did.
>
> Tested: StarLite ADL with an RTS5129 tray reader; repeated 1.8V UHS
> sessions, power cycles, and tray removal/reinsertion.
> Tested: StarFighter MTL with an RTS5129 trayless reader; repeated 1.8V
> UHS sessions, power cycles, and card removal/reinsertion.
> Tested: Both systems re-enumerated the card after every cycle.
>
> Signed-off-by: Sean Rhodes <sean@starlabs.systems>
Applied for next (or should this be a fix and tagged for stable?), thanks!
Kind regards
Uffe
> ---
> drivers/mmc/host/rtsx_usb_sdmmc.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/drivers/mmc/host/rtsx_usb_sdmmc.c b/drivers/mmc/host/rtsx_usb_sdmmc.c
> index bf37fab233cf..d9b33aa79165 100644
> --- a/drivers/mmc/host/rtsx_usb_sdmmc.c
> +++ b/drivers/mmc/host/rtsx_usb_sdmmc.c
> @@ -980,6 +980,11 @@ static int sd_power_on(struct rtsx_usb_sdmmc *host)
> }
> dev_dbg(sdmmc_dev(host), "%s\n", __func__);
> rtsx_usb_init_cmd(ucr);
> + /* Start SD init at 3.3V, like the old rts5139 driver. */
> + rtsx_usb_add_cmd(ucr, WRITE_REG_CMD, SD_PAD_CTL,
> + SD_IO_USING_1V8, SD_IO_USING_3V3);
> + rtsx_usb_add_cmd(ucr, WRITE_REG_CMD, LDO_POWER_CFG,
> + TUNE_SD18_MASK, TUNE_SD18_3V3);
> rtsx_usb_add_cmd(ucr, WRITE_REG_CMD, CARD_SELECT, 0x07, SD_MOD_SEL);
> rtsx_usb_add_cmd(ucr, WRITE_REG_CMD, CARD_SHARE_MODE,
> CARD_SHARE_MASK, CARD_SHARE_SD);