[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAPDyKFrg4-QxDpE_MkQacK_VRA6yQyFk4N3umZ1i2D=RTQisAA@mail.gmail.com>
Date: Wed, 21 Jan 2026 11:16:48 +0100
From: Ulf Hansson <ulf.hansson@...aro.org>
To: Matthew Schwartz <matthew.schwartz@...ux.dev>
Cc: Arnd Bergmann <arnd@...db.de>, Ricky Wu <ricky_wu@...ltek.com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>, linux-mmc@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/2] mmc: rtsx: reset power state on suspend
On Tue, 20 Jan 2026 at 19:39, Matthew Schwartz
<matthew.schwartz@...ux.dev> wrote:
>
> On 1/20/26 4:41 AM, Ulf Hansson wrote:
> > On Mon, 5 Jan 2026 at 07:02, Matthew Schwartz
> > <matthew.schwartz@...ux.dev> wrote:
> >>
> >> When rtsx_pci suspends, the card reader hardware powers off but the sdmmc
> >> driver's prev_power_state remains as MMC_POWER_ON. This causes sd_power_on
> >> to skip reinitialization on the next I/O request, leading to DMA transfer
> >> timeouts and errors on resume 20% of the time.
> >
> > The mmc core should power-off the card, via the ->set_ios() callback
> > before the rtsx_pci suspends. In other words, the mmc core should have
> > set MMC_POWER_OFF.
> >
> > That said, there seems to be something wrong in
> > drivers/mmc/host/rtsx_pci_sdmmc.c's ->set_ios(), if that isn't tracked
> > correctly. The parent device/driver, rtsx_pci should not need to
> > inform that the power to the card is removed, as that should be known
> > already by the rtsx_pci_sdmmc driver.
>
> Ah, I see what you mean now, I think it should be fixed in rtsx_pci_sdmmc
> too.
>
> These already seem to be in char-misc-next, so I think I need to wait
> until those hit upstream and then revert as a part of a v2 patch? If I revert
> from char-misc-next I'm worried the commit id won't match once it gets merged
> into master.
I have asked Greg to drop them from his misc tree. We should either do
that or revert them in his tree. Let's see what he responds.
In the meantime, it's perfectly possible to continue working on the
issue and please base your patches on top of the mmc tree.
[...]
Kind regards
Uffe
Powered by blists - more mailing lists