From: Chen Wang <unicornxw@gmail.com>
To: adrian.hunter@intel.com, aou@eecs.berkeley.edu,
conor+dt@kernel.org, guoren@kernel.org, inochiama@outlook.com,
jszhang@kernel.org, krzysztof.kozlowski+dt@linaro.org,
palmer@dabbelt.com, paul.walmsley@sifive.com, robh@kernel.org,
ulf.hansson@linaro.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-mmc@vger.kernel.org,
linux-riscv@lists.infradead.org, chao.wei@sophgo.com,
haijiao.liu@sophgo.com, xiaoguang.xing@sophgo.com,
tingzhu.wang@sophgo.com
Cc: Chen Wang <unicorn_wang@outlook.com>
Subject: [PATCH v6 0/8] mmc: sdhci-of-dwcmshc: Add Sophgo SG2042 support
Date: Mon, 5 Aug 2024 17:15:18 +0800 [thread overview]
Message-ID: <cover.1722847198.git.unicorn_wang@outlook.com> (raw)
From: Chen Wang <unicorn_wang@outlook.com>
This patchset is composed of two parts:
- one is the improvement of the sdhci-of-dwcmshc framework,
- the other is the support for sg2042 based on the improvement of the
framework.
The reason for merging the two parts into one patchset is mainly to
facilitate review, especially to facilitate viewing why we need to
improve the framework and what benefits it will bring to us.
When I tried to add a new soc(SG2042) to sdhci-of-dwcmshc, I found
that the existing driver code could be optimized to facilitate expansion
for the new soc. Patch 1 ~ Patch 5 is for this.
Patch 6 ~ 7 are adding support for the mmc controller for Sophgo SG2042.
Adding corresponding new compatible strings, and implement
custom callbacks for SG2042 based on new framework.
Patch 8 is the change for DTS.
By the way, although I believe this patch only optimizes the framework
of the code and does not change the specific logic, simple verification
is certainly better. Since I don't have rk35xx/th1520 related hardware,
it would be greatly appreciated if someone could help verify it.
---
Changes in v6:
The patch series is based on latest 'next' branch of [mmc-git].
- Some minor improvements based on Adrian's review suggestions.
- Added Reviewed-by and Tested-by signatures from Conor/Drew/Inochi.
Changes in v5:
The patch series is based on latest 'next' branch of [mmc-git]. You can simply
review or test the patches at the link [5].
- Based on Adrian's suggestion, split the first part of the patch into 5.
- Updated bindings and DTS as per suggestion from Krzysztof, Jisheng and Conor.
Changes in v4:
The patch series is based on latest 'next' branch of [mmc-git]. You can simply
review or test the patches at the link [4].
Improved the dirvier code as per comments from Adrian Hunter, drop moving
position and renaming for some helper functions.
Put the sg2042 support as part of this series, improve the bindings and code
as per comments from last review.
Changes in v3:
The patch series is based on latest 'next' branch of [mmc-git]. You can simply
review or test the patches at the link [3].
Improved the dirvier code as per comments from Adrian Hunter.
Define new structure for dwcmshc platform data/ops. In addition, I organized
the code and classified the helper functions.
Since the file changes were relatively large (though the functional logic did
not change much), I split the original patch into four for the convenience of
review.
Changes in v2:
Rebased on latest 'next' branch of [mmc-git]. You can simply review or test the
patches at the link [2].
Changes in v1:
The patch series is based on v6.9-rc1. You can simply review or test the
patches at the link [1].
Link: git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc.git [mmc-git]
Link: https://lore.kernel.org/linux-mmc/cover.1713257181.git.unicorn_wang@outlook.com/ [1]
Link: https://lore.kernel.org/linux-mmc/cover.1714270290.git.unicorn_wang@outlook.com/ [2]
Link: https://lore.kernel.org/linux-mmc/cover.1718241495.git.unicorn_wang@outlook.com/ [3]
Link: https://lore.kernel.org/linux-mmc/cover.1718697954.git.unicorn_wang@outlook.com/ [4]
Link: https://lore.kernel.org/linux-mmc/cover.1721377374.git.unicorn_wang@outlook.com/ [5]
---
Chen Wang (8):
mmc: sdhci-of-dwcmshc: add common bulk optional clocks support
mmc: sdhci-of-dwcmshc: move two rk35xx functions
mmc: sdhci-of-dwcmshc: factor out code for th1520_init()
mmc: sdhci-of-dwcmshc: factor out code into dwcmshc_rk35xx_init
mmc: sdhci-of-dwcmshc: add dwcmshc_pltfm_data
dt-bindings: mmc: sdhci-of-dwcmhsc: Add Sophgo SG2042 support
mmc: sdhci-of-dwcmshc: Add support for Sophgo SG2042
riscv: sophgo: dts: add mmc controllers for SG2042 SoC
.../bindings/mmc/snps,dwcmshc-sdhci.yaml | 60 ++-
.../boot/dts/sophgo/sg2042-milkv-pioneer.dts | 17 +
arch/riscv/boot/dts/sophgo/sg2042.dtsi | 28 ++
drivers/mmc/host/sdhci-of-dwcmshc.c | 451 ++++++++++++------
4 files changed, 383 insertions(+), 173 deletions(-)
base-commit: 538076ce6b8dfe5e8e8d9d250298030f165d8457
--
2.34.1
next reply other threads:[~2024-08-05 9:15 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-05 9:15 Chen Wang [this message]
2024-08-05 9:17 ` [PATCH v6 1/8] mmc: sdhci-of-dwcmshc: add common bulk optional clocks support Chen Wang
2024-08-08 7:17 ` Adrian Hunter
2025-07-22 18:33 ` Robin Murphy
2025-07-23 5:33 ` Adrian Hunter
2025-07-24 14:33 ` Diederik de Haas
2025-07-24 14:57 ` Adrian Hunter
2025-07-25 17:03 ` Diederik de Haas
2024-08-05 9:17 ` [PATCH v6 2/8] mmc: sdhci-of-dwcmshc: move two rk35xx functions Chen Wang
2024-08-08 7:18 ` Adrian Hunter
2024-08-05 9:17 ` [PATCH v6 3/8] mmc: sdhci-of-dwcmshc: factor out code for th1520_init() Chen Wang
2024-08-08 7:18 ` Adrian Hunter
2024-08-05 9:18 ` [PATCH v6 4/8] mmc: sdhci-of-dwcmshc: factor out code into dwcmshc_rk35xx_init Chen Wang
2024-08-08 7:19 ` Adrian Hunter
2024-08-05 9:18 ` [PATCH v6 5/8] mmc: sdhci-of-dwcmshc: add dwcmshc_pltfm_data Chen Wang
2024-08-08 7:19 ` Adrian Hunter
2024-08-05 9:19 ` [PATCH v6 6/8] dt-bindings: mmc: sdhci-of-dwcmhsc: Add Sophgo SG2042 support Chen Wang
2024-08-05 9:19 ` [PATCH v6 7/8] mmc: sdhci-of-dwcmshc: Add support for Sophgo SG2042 Chen Wang
2024-08-08 7:19 ` Adrian Hunter
2024-08-05 9:19 ` [PATCH v6 8/8] riscv: sophgo: dts: add mmc controllers for SG2042 SoC Chen Wang
2024-08-20 11:49 ` [PATCH v6 0/8] mmc: sdhci-of-dwcmshc: Add Sophgo SG2042 support Ulf Hansson
2024-08-26 2:59 ` (subset) " Inochi Amaoto
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cover.1722847198.git.unicorn_wang@outlook.com \
--to=unicornxw@gmail.com \
--cc=adrian.hunter@intel.com \
--cc=aou@eecs.berkeley.edu \
--cc=chao.wei@sophgo.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=guoren@kernel.org \
--cc=haijiao.liu@sophgo.com \
--cc=inochiama@outlook.com \
--cc=jszhang@kernel.org \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mmc@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=palmer@dabbelt.com \
--cc=paul.walmsley@sifive.com \
--cc=robh@kernel.org \
--cc=tingzhu.wang@sophgo.com \
--cc=ulf.hansson@linaro.org \
--cc=unicorn_wang@outlook.com \
--cc=xiaoguang.xing@sophgo.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).