linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1 0/2] Add mmc support for mt7988
@ 2024-10-06 10:21 Frank Wunderlich
  2024-10-06 10:21 ` [PATCH v1 1/2] dt-bindings: mmc: mtk-sd: Add mt7988 SoC Frank Wunderlich
  2024-10-06 10:21 ` [PATCH v1 2/2] mmc: mtk-sd: add support for mt7988 Frank Wunderlich
  0 siblings, 2 replies; 5+ messages in thread
From: Frank Wunderlich @ 2024-10-06 10:21 UTC (permalink / raw)
  To: Chaotian Jing, Ulf Hansson, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Matthias Brugger, AngeloGioacchino Del Regno,
	Wenbin Mei
  Cc: Frank Wunderlich, linux-mmc, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, daniel, linux-gpio, john,
	eladwf, ansuelsmth

From: Frank Wunderlich <frank-w@public-files.de>

Add MMC-Support for MT798 SoC

Frank Wunderlich (2):
  dt-bindings: mmc: mtk-sd: Add mt7988 SoC
  mmc: mtk-sd: add support for mt7988

 .../devicetree/bindings/mmc/mtk-sd.yaml       | 24 +++++++++++++++++++
 drivers/mmc/host/mtk-sd.c                     | 14 +++++++++++
 2 files changed, 38 insertions(+)

-- 
2.43.0


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH v1 1/2] dt-bindings: mmc: mtk-sd: Add mt7988 SoC
  2024-10-06 10:21 [PATCH v1 0/2] Add mmc support for mt7988 Frank Wunderlich
@ 2024-10-06 10:21 ` Frank Wunderlich
  2024-10-06 12:47   ` Krzysztof Kozlowski
  2024-10-06 10:21 ` [PATCH v1 2/2] mmc: mtk-sd: add support for mt7988 Frank Wunderlich
  1 sibling, 1 reply; 5+ messages in thread
From: Frank Wunderlich @ 2024-10-06 10:21 UTC (permalink / raw)
  To: Chaotian Jing, Ulf Hansson, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Matthias Brugger, AngeloGioacchino Del Regno,
	Wenbin Mei
  Cc: Frank Wunderlich, linux-mmc, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, daniel, linux-gpio, john,
	eladwf, ansuelsmth

From: Frank Wunderlich <frank-w@public-files.de>

Add binding definitions for mmc on MT7988 SoC.

Signed-off-by: Frank Wunderlich <frank-w@public-files.de>
---
 .../devicetree/bindings/mmc/mtk-sd.yaml       | 24 +++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/Documentation/devicetree/bindings/mmc/mtk-sd.yaml b/Documentation/devicetree/bindings/mmc/mtk-sd.yaml
index c532ec92d2d9..db7d1c570aea 100644
--- a/Documentation/devicetree/bindings/mmc/mtk-sd.yaml
+++ b/Documentation/devicetree/bindings/mmc/mtk-sd.yaml
@@ -21,6 +21,7 @@ properties:
           - mediatek,mt7620-mmc
           - mediatek,mt7622-mmc
           - mediatek,mt7986-mmc
+          - mediatek,mt7988-mmc
           - mediatek,mt8135-mmc
           - mediatek,mt8173-mmc
           - mediatek,mt8183-mmc
@@ -263,6 +264,29 @@ allOf:
             - const: bus_clk
             - const: sys_cg
 
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - mediatek,mt7988-mmc
+    then:
+      properties:
+        clocks:
+          minItems: 3
+          items:
+            - description: source clock
+            - description: HCLK which used for host
+            - description: Advanced eXtensible Interface
+            - description: Advanced High-performance Bus clock
+        clock-names:
+          minItems: 3
+          items:
+            - const: source
+            - const: hclk
+            - const: axi_cg
+            - const: ahb_cg
+
   - if:
       properties:
         compatible:
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH v1 2/2] mmc: mtk-sd: add support for mt7988
  2024-10-06 10:21 [PATCH v1 0/2] Add mmc support for mt7988 Frank Wunderlich
  2024-10-06 10:21 ` [PATCH v1 1/2] dt-bindings: mmc: mtk-sd: Add mt7988 SoC Frank Wunderlich
@ 2024-10-06 10:21 ` Frank Wunderlich
  1 sibling, 0 replies; 5+ messages in thread
From: Frank Wunderlich @ 2024-10-06 10:21 UTC (permalink / raw)
  To: Chaotian Jing, Ulf Hansson, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Matthias Brugger, AngeloGioacchino Del Regno,
	Wenbin Mei
  Cc: Frank Wunderlich, linux-mmc, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, daniel, linux-gpio, john,
	eladwf, ansuelsmth

From: Frank Wunderlich <frank-w@public-files.de>

Add support for mmc on MT7988 SoC.

Signed-off-by: Frank Wunderlich <frank-w@public-files.de>
---
 drivers/mmc/host/mtk-sd.c | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/drivers/mmc/host/mtk-sd.c b/drivers/mmc/host/mtk-sd.c
index 89018b6c97b9..6d5afe51a61d 100644
--- a/drivers/mmc/host/mtk-sd.c
+++ b/drivers/mmc/host/mtk-sd.c
@@ -571,6 +571,19 @@ static const struct mtk_mmc_compatible mt7986_compat = {
 	.support_64g = true,
 };
 
+static const struct mtk_mmc_compatible mt7988_compat = {
+	.clk_div_bits = 12,
+	.recheck_sdio_irq = true,
+	.hs400_tune = false,
+	.pad_tune_reg = MSDC_PAD_TUNE0,
+	.async_fifo = true,
+	.data_tune = true,
+	.busy_check = true,
+	.stop_clk_fix = true,
+	.enhance_rx = true,
+	.support_64g = true,
+};
+
 static const struct mtk_mmc_compatible mt8135_compat = {
 	.clk_div_bits = 8,
 	.recheck_sdio_irq = true,
@@ -629,6 +642,7 @@ static const struct of_device_id msdc_of_ids[] = {
 	{ .compatible = "mediatek,mt7620-mmc", .data = &mt7620_compat},
 	{ .compatible = "mediatek,mt7622-mmc", .data = &mt7622_compat},
 	{ .compatible = "mediatek,mt7986-mmc", .data = &mt7986_compat},
+	{ .compatible = "mediatek,mt7988-mmc", .data = &mt7988_compat},
 	{ .compatible = "mediatek,mt8135-mmc", .data = &mt8135_compat},
 	{ .compatible = "mediatek,mt8173-mmc", .data = &mt8173_compat},
 	{ .compatible = "mediatek,mt8183-mmc", .data = &mt8183_compat},
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH v1 1/2] dt-bindings: mmc: mtk-sd: Add mt7988 SoC
  2024-10-06 10:21 ` [PATCH v1 1/2] dt-bindings: mmc: mtk-sd: Add mt7988 SoC Frank Wunderlich
@ 2024-10-06 12:47   ` Krzysztof Kozlowski
  2024-10-06 15:13     ` Aw: " Frank Wunderlich
  0 siblings, 1 reply; 5+ messages in thread
From: Krzysztof Kozlowski @ 2024-10-06 12:47 UTC (permalink / raw)
  To: Frank Wunderlich
  Cc: Chaotian Jing, Ulf Hansson, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Matthias Brugger, AngeloGioacchino Del Regno,
	Wenbin Mei, Frank Wunderlich, linux-mmc, devicetree, linux-kernel,
	linux-arm-kernel, linux-mediatek, daniel, linux-gpio, john,
	eladwf, ansuelsmth

On Sun, Oct 06, 2024 at 12:21:48PM +0200, Frank Wunderlich wrote:
> From: Frank Wunderlich <frank-w@public-files.de>
> 
> Add binding definitions for mmc on MT7988 SoC.
> 
> Signed-off-by: Frank Wunderlich <frank-w@public-files.de>
> ---
>  .../devicetree/bindings/mmc/mtk-sd.yaml       | 24 +++++++++++++++++++
>  1 file changed, 24 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/mmc/mtk-sd.yaml b/Documentation/devicetree/bindings/mmc/mtk-sd.yaml
> index c532ec92d2d9..db7d1c570aea 100644
> --- a/Documentation/devicetree/bindings/mmc/mtk-sd.yaml
> +++ b/Documentation/devicetree/bindings/mmc/mtk-sd.yaml
> @@ -21,6 +21,7 @@ properties:
>            - mediatek,mt7620-mmc
>            - mediatek,mt7622-mmc
>            - mediatek,mt7986-mmc
> +          - mediatek,mt7988-mmc
>            - mediatek,mt8135-mmc
>            - mediatek,mt8173-mmc
>            - mediatek,mt8183-mmc
> @@ -263,6 +264,29 @@ allOf:
>              - const: bus_clk
>              - const: sys_cg
>  
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - mediatek,mt7988-mmc
> +    then:
> +      properties:
> +        clocks:
> +          minItems: 3
> +          items:
> +            - description: source clock
> +            - description: HCLK which used for host
> +            - description: Advanced eXtensible Interface
> +            - description: Advanced High-performance Bus clock

Why ahb is optional?

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Aw: Re: [PATCH v1 1/2] dt-bindings: mmc: mtk-sd: Add mt7988 SoC
  2024-10-06 12:47   ` Krzysztof Kozlowski
@ 2024-10-06 15:13     ` Frank Wunderlich
  0 siblings, 0 replies; 5+ messages in thread
From: Frank Wunderlich @ 2024-10-06 15:13 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Frank Wunderlich, Chaotian Jing, Ulf Hansson, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Matthias Brugger,
	AngeloGioacchino Del Regno, Wenbin Mei, linux-mmc, devicetree,
	linux-kernel, linux-arm-kernel, linux-mediatek, daniel,
	linux-gpio, john, eladwf, ansuelsmth

Hi

> Gesendet: Sonntag, 06. Oktober 2024 um 14:47 Uhr
> Von: "Krzysztof Kozlowski" <krzk@kernel.org>
> An: "Frank Wunderlich" <linux@fw-web.de>
> Betreff: Re: [PATCH v1 1/2] dt-bindings: mmc: mtk-sd: Add mt7988 SoC
>
> On Sun, Oct 06, 2024 at 12:21:48PM +0200, Frank Wunderlich wrote:
> > From: Frank Wunderlich <frank-w@public-files.de>
> >
> > Add binding definitions for mmc on MT7988 SoC.
> >
> > Signed-off-by: Frank Wunderlich <frank-w@public-files.de>
> > ---
> >  .../devicetree/bindings/mmc/mtk-sd.yaml       | 24 +++++++++++++++++++
> >  1 file changed, 24 insertions(+)
> >
> > diff --git a/Documentation/devicetree/bindings/mmc/mtk-sd.yaml b/Documentation/devicetree/bindings/mmc/mtk-sd.yaml
> > index c532ec92d2d9..db7d1c570aea 100644
> > --- a/Documentation/devicetree/bindings/mmc/mtk-sd.yaml
> > +++ b/Documentation/devicetree/bindings/mmc/mtk-sd.yaml
> > @@ -21,6 +21,7 @@ properties:
> >            - mediatek,mt7620-mmc
> >            - mediatek,mt7622-mmc
> >            - mediatek,mt7986-mmc
> > +          - mediatek,mt7988-mmc
> >            - mediatek,mt8135-mmc
> >            - mediatek,mt8173-mmc
> >            - mediatek,mt8183-mmc
> > @@ -263,6 +264,29 @@ allOf:
> >              - const: bus_clk
> >              - const: sys_cg
> >
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - mediatek,mt7988-mmc
> > +    then:
> > +      properties:
> > +        clocks:
> > +          minItems: 3
> > +          items:
> > +            - description: source clock
> > +            - description: HCLK which used for host
> > +            - description: Advanced eXtensible Interface
> > +            - description: Advanced High-performance Bus clock
>
> Why ahb is optional?

sorry, my fault, forgot to change the minitems property after copy the block

> Best regards,
> Krzysztof


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2024-10-06 15:13 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-06 10:21 [PATCH v1 0/2] Add mmc support for mt7988 Frank Wunderlich
2024-10-06 10:21 ` [PATCH v1 1/2] dt-bindings: mmc: mtk-sd: Add mt7988 SoC Frank Wunderlich
2024-10-06 12:47   ` Krzysztof Kozlowski
2024-10-06 15:13     ` Aw: " Frank Wunderlich
2024-10-06 10:21 ` [PATCH v1 2/2] mmc: mtk-sd: add support for mt7988 Frank Wunderlich

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).