RE: [PATCH v20 00/12] Add Renesas RZ/G3L SD/eMMC support
Biju Das <[email protected]> Fri, 17 Jul 2026 08:20:59 +0000
| Newsgroups | org.kernel.vger.linux-mmc,org.kernel.vger.linux-devicetree,org.kernel.vger.linux-kernel,org.kernel.vger.linux-renesas-soc |
|---|---|
| Message-ID | <TY3PR01MB11346742C360354F9442B784E86C62@TY3PR01MB11346.jpnprd01.prod.outlook.com> |
Hi All, I got an update from hardware team for CLK divider bits for HS400 mode. This change will incorporate in next version of hardware manual. For HS400 mode: 00 0000 0000b: (SDxφ/2)/2 Other settings are prohibited. Cheers, Biju > -----Original Message----- > From: Biju <[email protected]> > Sent: 13 July 2026 18:52 > To: Ulf Hansson <[email protected]>; Rob Herring <[email protected]>; Krzysztof Kozlowski > <[email protected]>; Conor Dooley <[email protected]>; Geert Uytterhoeven <[email protected]>; > Philipp Zabel <[email protected]>; magnus.damm <[email protected]> > Cc: Biju Das <[email protected]>; wsa+renesas <[email protected]>; linux- > [email protected]; [email protected]; [email protected]; linux-renesas- > [email protected]; Prabhakar Mahadev Lad <[email protected]>; biju.das.au > <[email protected]> > Subject: [PATCH v20 00/12] Add Renesas RZ/G3L SD/eMMC support > > From: Biju Das <[email protected]> > > Hi All, > > RZ/G3L SoC has: > > Channel 0 supports SD and eMMC (including HS400/HS400ES). > Channel 1 supports SD and eMMC (except for HS400). > Channel 2 supports SD. > > The SoC supports a maximum frequency of 150 MHz. The SD0 interface does not support IOVS and PWEN in the > SDHI register (no internal regulator), unlike SD1 and SD2. It has an internal divider for all modes > except HS400. > It also has a 2048-bit divider compared to 512 on others. Moreover RZ/G3L supports HS400 enhanced strobe > mode. > > v19->v20: > * Replaced the check mmd->clk_mask with mmc_data->clk_mask and moved > the code after assignment of variable mmd, this ensures assigning > the default values for non-DT platforms and DT platforms with no > device data. > * Replaced the check mmd->max_divider with mmc_data->max_divider and > moved the code after assignment of variable mmd, this ensures > assigning the default values for non-DT platforms and DT platforms with > no device data. > * Fixed the ordering of resets in suspend/resume paths. > * Added bitfield.h header file. > * Reworked on renesas_sdhi_set_clock() to handle the 11-bit divider > case and the 32-bit register write. > * Updated resume() with scoped PM runtime call. > * SD_CLK_CTRL clk enable turned off before updating SCC_CKSEL_DTSEL > register. > v18->v19: > * Updated commit description for patch#1,#2,#6,#8,#11 and #12 > * Updated clock and reset description with AXI master and AXI slave > * Added else condition for reset and reset-names. > * Renamed aclk->aclkm and reordered the axi clocks similar to resets. > * Retained the tag got binding patch as the changes are trivial. > * Fixed the clk_mask for non-DT platforms. > * Fixed max-divider setting for non-DT platforms. > * Replaced the magic number '9' with ilog2 function in > renesas_sdhi_clk_enable(). > * Dropped divider variable from struct renesas_sdhi. > * Updated renesas_sdhi_clk_update() to return rate for HS400 mode > and non HS400 mode(uses 1/2 internal divider). > * Updated handling for clk divider. > * Renamed TMIO_MMC_HWADJ2->TMIO_MMC_HWADJ to make it generic for > hardware tuning delays > * Dropped duplicate SH_MOBILE_SDHI_SCC_TMPPORT2 macro > * Updated suspend/resume with scoped runtime calls in suspend. > * Fixed extra space in HS400MODE2 comment block. > * Updated the comment HS400mode2->HS400MODE2. > * Dropped the updation of clk handling as it is taken care in > previous patches. > * HS400ES support is enabled based on of_data. > * Fixed the space in HS400ES comment block. > > v17->v18: > * Collected tag > * Merged patch #4 and #5 and updated commit description > * Annotated the empty sentinel entries in the OF match tables with a > "Sentinel." comment for clarity. > * Retained the tag as it is a trivial cleanup. > * New patches drop struct renesas_sdhi_hw_info, instead using > renesas_sdhi_of_data and tmio_mmc_data. > * Dropped clk, pinctrl, SoC, and board dtsi from this patch series; > will send later. > v1->v17: > * Collected tag for binding patch. > * Resending the series as there is an issue with patch threading from > patch #14. > > Biju Das (12): > dt-bindings: mmc: renesas,sdhi: Document RZ/G3L (r9a08g046) SoC > mmc: renesas_sdhi: Clean up whitespace and add OF table sentinels > mmc: renesas_sdhi: Add clk_mask field to support flexible clock > divider widths > mmc: renesas_sdhi: Add max_divider field to support SoC-specific clock > ranges > mmc: renesas_sdhi: Add tuning delay support for RZ/G2L > mmc: renesas_sdhi: Add TMIO_MMC_INTERNAL_DIVIDER flag > mmc: renesas_sdhi: Add optional axis/axim reset controls > mmc: renesas_sdhi: Add RZ/G3L SDHI support > mmc: renesas_sdhi: Save and restore IOVS across suspend/resume > mmc: renesas_sdhi: Make HS400 OSEL bit configurable per SoC > mmc: renesas_sdhi: Add RZ/G3L HS400 support > mmc: renesas_sdhi: Add HS400 enhanced strobe support for RZ/G3L > > .../devicetree/bindings/mmc/renesas,sdhi.yaml | 108 +++++-- > drivers/mmc/host/renesas_sdhi.h | 11 +- > drivers/mmc/host/renesas_sdhi_core.c | 274 ++++++++++++++---- > drivers/mmc/host/renesas_sdhi_internal_dmac.c | 73 ++++- > drivers/mmc/host/renesas_sdhi_sys_dmac.c | 12 +- > include/linux/platform_data/tmio.h | 18 ++ > 6 files changed, 408 insertions(+), 88 deletions(-) > > -- > 2.43.0