mbox series

[RFC,0/4] mmc: renesas_sdhi: reset SCC only when available

Message ID 20201110142058.36393-1-wsa+renesas@sang-engineering.com (mailing list archive)
Headers show
Series mmc: renesas_sdhi: reset SCC only when available | expand

Message

Wolfram Sang Nov. 10, 2020, 2:20 p.m. UTC
While working on another improvement for the reset routine, I noted an
issue with an old Gen2 SDHI instance which did not have a SCC. It turned
out that we never distinguished between the SCC and non-SCC versions on
Gen2 when it came to resetting. So far, it went OK but my upcoming
change broke. So, this series fixes the underlying issue by only
resetting the SCC when one is available.

I made very fine-grained patches because this driver is so fragile.
Nonetheless, my tests on a Renesas Lager board (R-Car H2) and
Salvator-XS (R-Car M3-N) were successful. Debug output showed that
proper code paths were taken and checksumming large files worked as well
as reinserting cards. The patches are based on mmc/next and 5.11 will
do because there seems to be no issue with current kernels.

I'd be very happy about further review and testing!

Thanks and all the best,

   Wolfram


Wolfram Sang (4):
  mmc: renesas_sdhi: only reset SCC when its pointer is populated
  mmc: renesas_sdhi: probe into TMIO after SCC parameters have been
    setup
  mmc: renesas_sdhi: populate SCC pointer at the proper place
  mmc: renesas_sdhi: simplify reset routine a little

 drivers/mmc/host/renesas_sdhi_core.c | 38 +++++++++++++---------------
 1 file changed, 18 insertions(+), 20 deletions(-)

Comments

Yoshihiro Shimoda Nov. 13, 2020, 5 a.m. UTC | #1
Hi Wolfram-san,

> From: Wolfram Sang, Sent: Tuesday, November 10, 2020 11:21 PM
> 
> While working on another improvement for the reset routine, I noted an
> issue with an old Gen2 SDHI instance which did not have a SCC. It turned
> out that we never distinguished between the SCC and non-SCC versions on
> Gen2 when it came to resetting. So far, it went OK but my upcoming
> change broke. So, this series fixes the underlying issue by only
> resetting the SCC when one is available.
> 
> I made very fine-grained patches because this driver is so fragile.
> Nonetheless, my tests on a Renesas Lager board (R-Car H2) and
> Salvator-XS (R-Car M3-N) were successful. Debug output showed that
> proper code paths were taken and checksumming large files worked as well
> as reinserting cards. The patches are based on mmc/next and 5.11 will
> do because there seems to be no issue with current kernels.
> 
> I'd be very happy about further review and testing!

Thank you for the patch!

Reviewed-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>

And, I tested on Salvator-XS (R-Car H3 and R-Car M3-W+). So,

Tested-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>

Best regards,
Yoshihiro Shimoda
Ulf Hansson Nov. 17, 2020, 11:49 a.m. UTC | #2
On Tue, 10 Nov 2020 at 15:21, Wolfram Sang
<wsa+renesas@sang-engineering.com> wrote:
>
> While working on another improvement for the reset routine, I noted an
> issue with an old Gen2 SDHI instance which did not have a SCC. It turned
> out that we never distinguished between the SCC and non-SCC versions on
> Gen2 when it came to resetting. So far, it went OK but my upcoming
> change broke. So, this series fixes the underlying issue by only
> resetting the SCC when one is available.
>
> I made very fine-grained patches because this driver is so fragile.
> Nonetheless, my tests on a Renesas Lager board (R-Car H2) and
> Salvator-XS (R-Car M3-N) were successful. Debug output showed that
> proper code paths were taken and checksumming large files worked as well
> as reinserting cards. The patches are based on mmc/next and 5.11 will
> do because there seems to be no issue with current kernels.
>
> I'd be very happy about further review and testing!
>
> Thanks and all the best,
>
>    Wolfram
>
>
> Wolfram Sang (4):
>   mmc: renesas_sdhi: only reset SCC when its pointer is populated
>   mmc: renesas_sdhi: probe into TMIO after SCC parameters have been
>     setup
>   mmc: renesas_sdhi: populate SCC pointer at the proper place
>   mmc: renesas_sdhi: simplify reset routine a little
>
>  drivers/mmc/host/renesas_sdhi_core.c | 38 +++++++++++++---------------
>  1 file changed, 18 insertions(+), 20 deletions(-)

Applied for next, thanks!

Kind regards
Uffe