* [v0.1 PATCH 0/7] mmc: tmio: refactor TMIO core a bit and add UniPhier SD/eMMC controller support
@ 2018-08-07 6:17 Masahiro Yamada
2018-08-07 6:17 ` [v0.1 PATCH 3/7] dt-bindings: mmc: add DT binding for UniPhier SD/eMMC controller Masahiro Yamada
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Masahiro Yamada @ 2018-08-07 6:17 UTC (permalink / raw)
To: Wolfram Sang, linux-mmc
Cc: Mark Rutland, devicetree, Ulf Hansson, Masahiro Yamada,
linux-kernel, linux-renesas-soc, Jassi Brar, Rob Herring,
Masami Hiramatsu, linux-arm-kernel
Add UniPhier SD/eMMC controller support.
As a preparation, I changed tmio_mmc_set_clock() to a platform hook.
The clock rate setting is platform-specific, and UniPhier variants
will add another way. I thought it would be better to split this
to a hook to avoid a mess.
Masahiro Yamada (7):
mmc: tmio: replace tmio_mmc_clk_stop() calls with tmio_mmc_set_clock()
mmc: tmio: move tmio_mmc_set_clock() to platform hook
dt-bindings: mmc: add DT binding for UniPhier SD/eMMC controller
mmc: uniphier-sd: add UniPhier SD/eMMC controller driver
mmc: renesas_sdhi: merge clk_{start,stop} functions to set_clock
mmc: renesas_sdhi: refactor CLK_CTL bit calculation
mmc: tmio: refactor CLK_CTL bit calculation
.../devicetree/bindings/mmc/uniphier-sd.txt | 60 ++
MAINTAINERS | 1 +
drivers/mmc/host/Kconfig | 10 +
drivers/mmc/host/Makefile | 1 +
drivers/mmc/host/renesas_sdhi_core.c | 40 +-
drivers/mmc/host/tmio_mmc.c | 56 ++
drivers/mmc/host/tmio_mmc.h | 4 +-
drivers/mmc/host/tmio_mmc_core.c | 79 +--
drivers/mmc/host/uniphier-sd.c | 694 +++++++++++++++++++++
9 files changed, 869 insertions(+), 76 deletions(-)
create mode 100644 Documentation/devicetree/bindings/mmc/uniphier-sd.txt
create mode 100644 drivers/mmc/host/uniphier-sd.c
--
2.7.4
^ permalink raw reply [flat|nested] 5+ messages in thread
* [v0.1 PATCH 3/7] dt-bindings: mmc: add DT binding for UniPhier SD/eMMC controller
2018-08-07 6:17 [v0.1 PATCH 0/7] mmc: tmio: refactor TMIO core a bit and add UniPhier SD/eMMC controller support Masahiro Yamada
@ 2018-08-07 6:17 ` Masahiro Yamada
2018-08-14 20:15 ` Rob Herring
2018-08-07 6:26 ` [v0.1 PATCH 0/7] mmc: tmio: refactor TMIO core a bit and add UniPhier SD/eMMC controller support Masahiro Yamada
2018-08-12 16:24 ` Wolfram Sang
2 siblings, 1 reply; 5+ messages in thread
From: Masahiro Yamada @ 2018-08-07 6:17 UTC (permalink / raw)
To: Wolfram Sang, linux-mmc
Cc: Mark Rutland, devicetree, Ulf Hansson, Masahiro Yamada,
linux-kernel, linux-renesas-soc, Jassi Brar, Rob Herring,
Masami Hiramatsu, linux-arm-kernel
This SD/eMMC controller is used for UniPhier SoC family.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
---
.../devicetree/bindings/mmc/uniphier-sd.txt | 60 ++++++++++++++++++++++
1 file changed, 60 insertions(+)
create mode 100644 Documentation/devicetree/bindings/mmc/uniphier-sd.txt
diff --git a/Documentation/devicetree/bindings/mmc/uniphier-sd.txt b/Documentation/devicetree/bindings/mmc/uniphier-sd.txt
new file mode 100644
index 0000000..49dd0fc
--- /dev/null
+++ b/Documentation/devicetree/bindings/mmc/uniphier-sd.txt
@@ -0,0 +1,60 @@
+UniPhier SD/eMMC controller
+
+Required properties:
+- compatible: should be one of the following:
+ "socionext,uniphier-sd-v2.91" - IP version 2.91
+ "socionext,uniphier-sd-v3.1" - IP version 3.1
+ "socionext,uniphier-sd-v3.1b" - IP version 3.1 (bug-fix ver.) [1]
+- reg: offset and length of the register set for the device.
+- interrupts: a single interrupt specifier.
+- clocks: a single clock specifier of the controller clock.
+- reset-names: should contain the following:
+ "host" - mandatory for all versions
+ "bridge" - should exist only for "socionext,uniphier-sd-v2.91"
+ "hw" - should exist if eMMC hw reset line is available
+- resets: a list of reset specifiers, corresponding to the reset-names
+
+[1] There are two different controller cores for version 3.1. The early
+ release had a bug in the DMA RX channel. The issue was fixed later,
+ but the version number was not incremented. Hence, the latter has
+ 'b' at the end of its compatible string.
+
+Optional properties:
+- pinctrl-names: if present, should contain the following:
+ "default" - should exist for all instances
+ "uhs" - should exist for SD instance with UHS support
+- pinctrl-0: pin control state for the default mode
+- pinctrl-1: pin control state for the UHS mode
+- dma-names: should be "rx-tx" if present.
+ This property can exist only for "socionext,uniphier-sd-v2.91".
+- dmas: a single DMA channel specifier
+ This property can exist only for "socionext,uniphier-sd-v2.91".
+- bus-width: see mmc.txt
+- cap-sd-highspeed: see mmc.txt
+- cap-mmc-highspeed: see mmc.txt
+- sd-uhs-sdr12: see mmc.txt
+- sd-uhs-sdr25: see mmc.txt
+- sd-uhs-sdr50: see mmc.txt
+- cap-mmc-hw-reset: should exist if reset-names contains "hw". see mmc.txt
+- non-removable: see mmc.txt
+
+Example:
+
+ sd: sdhc@5a400000 {
+ compatible = "socionext,uniphier-sd-v2.91";
+ reg = <0x5a400000 0x200>;
+ interrupts = <0 76 4>;
+ pinctrl-names = "default", "uhs";
+ pinctrl-0 = <&pinctrl_sd>;
+ pinctrl-1 = <&pinctrl_sd_uhs>;
+ clocks = <&mio_clk 0>;
+ reset-names = "host", "bridge";
+ resets = <&mio_rst 0>, <&mio_rst 3>;
+ dma-names = "rx-tx";
+ dmas = <&dmac 4>;
+ bus-width = <4>;
+ cap-sd-highspeed;
+ sd-uhs-sdr12;
+ sd-uhs-sdr25;
+ sd-uhs-sdr50;
+ };
--
2.7.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [v0.1 PATCH 0/7] mmc: tmio: refactor TMIO core a bit and add UniPhier SD/eMMC controller support
2018-08-07 6:17 [v0.1 PATCH 0/7] mmc: tmio: refactor TMIO core a bit and add UniPhier SD/eMMC controller support Masahiro Yamada
2018-08-07 6:17 ` [v0.1 PATCH 3/7] dt-bindings: mmc: add DT binding for UniPhier SD/eMMC controller Masahiro Yamada
@ 2018-08-07 6:26 ` Masahiro Yamada
2018-08-12 16:24 ` Wolfram Sang
2 siblings, 0 replies; 5+ messages in thread
From: Masahiro Yamada @ 2018-08-07 6:26 UTC (permalink / raw)
To: Wolfram Sang, linux-mmc
Cc: Ulf Hansson, Linux-Renesas, Masami Hiramatsu, Jassi Brar,
Masahiro Yamada, DTML, Linux Kernel Mailing List, Rob Herring,
Mark Rutland, linux-arm-kernel
2018-08-07 15:17 GMT+09:00 Masahiro Yamada <yamada.masahiro@socionext.com>:
> [v0.1 PATCH 0/7] mmc: tmio: refactor TMIO core a bit and add UniPhier SD/eMMC controller support
This series is v1.
v0.1 was the internal numbering, which I forgot to change.
--
Best Regards
Masahiro Yamada
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [v0.1 PATCH 0/7] mmc: tmio: refactor TMIO core a bit and add UniPhier SD/eMMC controller support
2018-08-07 6:17 [v0.1 PATCH 0/7] mmc: tmio: refactor TMIO core a bit and add UniPhier SD/eMMC controller support Masahiro Yamada
2018-08-07 6:17 ` [v0.1 PATCH 3/7] dt-bindings: mmc: add DT binding for UniPhier SD/eMMC controller Masahiro Yamada
2018-08-07 6:26 ` [v0.1 PATCH 0/7] mmc: tmio: refactor TMIO core a bit and add UniPhier SD/eMMC controller support Masahiro Yamada
@ 2018-08-12 16:24 ` Wolfram Sang
2 siblings, 0 replies; 5+ messages in thread
From: Wolfram Sang @ 2018-08-12 16:24 UTC (permalink / raw)
To: Masahiro Yamada
Cc: Wolfram Sang, linux-mmc, Ulf Hansson, linux-renesas-soc,
Masami Hiramatsu, Jassi Brar, devicetree, linux-kernel,
Rob Herring, Mark Rutland, linux-arm-kernel
Hi Yamada-san,
> Add UniPhier SD/eMMC controller support.
>
> As a preparation, I changed tmio_mmc_set_clock() to a platform hook.
> The clock rate setting is platform-specific, and UniPhier variants
> will add another way. I thought it would be better to split this
> to a hook to avoid a mess.
Thanks for this series! I see you did not base it on the renaming
patches. I think is a good decision because it would be a complicated
dependency. I had a glimpse on the patches and the new hook looks good
to me. I want to do full review and testing within the next two weeks.
Then, I can also comment about re-implementing the internal DMA core
handling vs. factorizing it out. It may be fine this way, I simply can't
tell now.
Regards,
Wolfram
>
>
>
> Masahiro Yamada (7):
> mmc: tmio: replace tmio_mmc_clk_stop() calls with tmio_mmc_set_clock()
> mmc: tmio: move tmio_mmc_set_clock() to platform hook
> dt-bindings: mmc: add DT binding for UniPhier SD/eMMC controller
> mmc: uniphier-sd: add UniPhier SD/eMMC controller driver
> mmc: renesas_sdhi: merge clk_{start,stop} functions to set_clock
> mmc: renesas_sdhi: refactor CLK_CTL bit calculation
> mmc: tmio: refactor CLK_CTL bit calculation
>
> .../devicetree/bindings/mmc/uniphier-sd.txt | 60 ++
> MAINTAINERS | 1 +
> drivers/mmc/host/Kconfig | 10 +
> drivers/mmc/host/Makefile | 1 +
> drivers/mmc/host/renesas_sdhi_core.c | 40 +-
> drivers/mmc/host/tmio_mmc.c | 56 ++
> drivers/mmc/host/tmio_mmc.h | 4 +-
> drivers/mmc/host/tmio_mmc_core.c | 79 +--
> drivers/mmc/host/uniphier-sd.c | 694 +++++++++++++++++++++
> 9 files changed, 869 insertions(+), 76 deletions(-)
> create mode 100644 Documentation/devicetree/bindings/mmc/uniphier-sd.txt
> create mode 100644 drivers/mmc/host/uniphier-sd.c
>
> --
> 2.7.4
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [v0.1 PATCH 3/7] dt-bindings: mmc: add DT binding for UniPhier SD/eMMC controller
2018-08-07 6:17 ` [v0.1 PATCH 3/7] dt-bindings: mmc: add DT binding for UniPhier SD/eMMC controller Masahiro Yamada
@ 2018-08-14 20:15 ` Rob Herring
0 siblings, 0 replies; 5+ messages in thread
From: Rob Herring @ 2018-08-14 20:15 UTC (permalink / raw)
Cc: Wolfram Sang, linux-mmc, Ulf Hansson, linux-renesas-soc,
Masami Hiramatsu, Jassi Brar, Masahiro Yamada, devicetree,
linux-kernel, Mark Rutland, linux-arm-kernel
On Tue, 7 Aug 2018 15:17:18 +0900, Masahiro Yamada <yamada.masahiro@socionext.com> wrote:
> This SD/eMMC controller is used for UniPhier SoC family.
>
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
> ---
>
> .../devicetree/bindings/mmc/uniphier-sd.txt | 60 ++++++++++++++++++++++
> 1 file changed, 60 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/mmc/uniphier-sd.txt
>
Reviewed-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2018-08-14 20:15 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-08-07 6:17 [v0.1 PATCH 0/7] mmc: tmio: refactor TMIO core a bit and add UniPhier SD/eMMC controller support Masahiro Yamada
2018-08-07 6:17 ` [v0.1 PATCH 3/7] dt-bindings: mmc: add DT binding for UniPhier SD/eMMC controller Masahiro Yamada
2018-08-14 20:15 ` Rob Herring
2018-08-07 6:26 ` [v0.1 PATCH 0/7] mmc: tmio: refactor TMIO core a bit and add UniPhier SD/eMMC controller support Masahiro Yamada
2018-08-12 16:24 ` Wolfram Sang
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).