2017-06-20 08:21:19

by Leilk Liu

[permalink] [raw]
Subject: [PATCH 0/2] add mt2712 spi support

This series are based on 4.12-rc1 and provide 2 patches to support mt2712 IC.

Change in this series:
1. update document to add mt2712;
2. add mt7622_compat.

Leilk Liu (2):
spi: mediatek: Add bindings for mediatek MT2712 soc platform
spi: mediatek: add spi support for mt2712 IC

.../devicetree/bindings/spi/spi-mt65xx.txt | 1 +
drivers/spi/spi-mt65xx.c | 7 +++++++
2 files changed, 8 insertions(+)

--
1.7.9.5


2017-06-20 08:21:27

by Leilk Liu

[permalink] [raw]
Subject: [PATCH 1/2] spi: mediatek: Add bindings for mediatek MT2712 soc platform

This patch adds a DT binding documentation for the MT2712 soc.

Signed-off-by: Leilk Liu <[email protected]>
---
.../devicetree/bindings/spi/spi-mt65xx.txt | 1 +
1 file changed, 1 insertion(+)

diff --git a/Documentation/devicetree/bindings/spi/spi-mt65xx.txt b/Documentation/devicetree/bindings/spi/spi-mt65xx.txt
index c0b1f01..e0318cf 100644
--- a/Documentation/devicetree/bindings/spi/spi-mt65xx.txt
+++ b/Documentation/devicetree/bindings/spi/spi-mt65xx.txt
@@ -3,6 +3,7 @@ Binding for MTK SPI controller
Required properties:
- compatible: should be one of the following.
- mediatek,mt2701-spi: for mt2701 platforms
+ - mediatek,mt2712-spi: for mt2712 platforms
- mediatek,mt6589-spi: for mt6589 platforms
- mediatek,mt7622-spi: for mt7622 platforms
- mediatek,mt8135-spi: for mt8135 platforms
--
1.7.9.5

2017-06-20 08:21:59

by Leilk Liu

[permalink] [raw]
Subject: [PATCH 2/2] spi: mediatek: add spi support for mt2712 IC

this patch add support for mt2712 IC.

Signed-off-by: Leilk Liu <[email protected]>
---
drivers/spi/spi-mt65xx.c | 7 +++++++
1 file changed, 7 insertions(+)

diff --git a/drivers/spi/spi-mt65xx.c b/drivers/spi/spi-mt65xx.c
index ec7755b..86bf456 100644
--- a/drivers/spi/spi-mt65xx.c
+++ b/drivers/spi/spi-mt65xx.c
@@ -105,6 +105,10 @@ struct mtk_spi {

static const struct mtk_spi_compatible mtk_common_compat;

+static const struct mtk_spi_compatible mt2712_compat = {
+ .must_tx = true,
+};
+
static const struct mtk_spi_compatible mt7622_compat = {
.must_tx = true,
.enhance_timing = true,
@@ -130,6 +134,9 @@ struct mtk_spi {
{ .compatible = "mediatek,mt2701-spi",
.data = (void *)&mtk_common_compat,
},
+ { .compatible = "mediatek,mt2712-spi",
+ .data = (void *)&mt2712_compat,
+ },
{ .compatible = "mediatek,mt6589-spi",
.data = (void *)&mtk_common_compat,
},
--
1.7.9.5

2017-06-20 10:12:33

by Matthias Brugger

[permalink] [raw]
Subject: Re: [PATCH 1/2] spi: mediatek: Add bindings for mediatek MT2712 soc platform



On 20/06/17 10:21, Leilk Liu wrote:
> This patch adds a DT binding documentation for the MT2712 soc.
>
> Signed-off-by: Leilk Liu <[email protected]>
> ---
> .../devicetree/bindings/spi/spi-mt65xx.txt | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/Documentation/devicetree/bindings/spi/spi-mt65xx.txt b/Documentation/devicetree/bindings/spi/spi-mt65xx.txt
> index c0b1f01..e0318cf 100644
> --- a/Documentation/devicetree/bindings/spi/spi-mt65xx.txt
> +++ b/Documentation/devicetree/bindings/spi/spi-mt65xx.txt
> @@ -3,6 +3,7 @@ Binding for MTK SPI controller
> Required properties:
> - compatible: should be one of the following.
> - mediatek,mt2701-spi: for mt2701 platforms
> + - mediatek,mt2712-spi: for mt2712 platforms
> - mediatek,mt6589-spi: for mt6589 platforms
> - mediatek,mt7622-spi: for mt7622 platforms
> - mediatek,mt8135-spi: for mt8135 platforms
>

Reviewed-by: Matthias Brugger <[email protected]>

2017-06-20 10:15:54

by Matthias Brugger

[permalink] [raw]
Subject: Re: [PATCH 2/2] spi: mediatek: add spi support for mt2712 IC



On 20/06/17 10:21, Leilk Liu wrote:
> this patch add support for mt2712 IC.
>
> Signed-off-by: Leilk Liu <[email protected]>
> ---
> drivers/spi/spi-mt65xx.c | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/drivers/spi/spi-mt65xx.c b/drivers/spi/spi-mt65xx.c
> index ec7755b..86bf456 100644
> --- a/drivers/spi/spi-mt65xx.c
> +++ b/drivers/spi/spi-mt65xx.c
> @@ -105,6 +105,10 @@ struct mtk_spi {
>
> static const struct mtk_spi_compatible mtk_common_compat;
>
> +static const struct mtk_spi_compatible mt2712_compat = {
> + .must_tx = true,
> +};
> +
> static const struct mtk_spi_compatible mt7622_compat = {
> .must_tx = true,
> .enhance_timing = true,
> @@ -130,6 +134,9 @@ struct mtk_spi {
> { .compatible = "mediatek,mt2701-spi",
> .data = (void *)&mtk_common_compat,
> },
> + { .compatible = "mediatek,mt2712-spi",
> + .data = (void *)&mt2712_compat,
> + },
> { .compatible = "mediatek,mt6589-spi",
> .data = (void *)&mtk_common_compat,
> },
>

Reviewed-by: Matthias Brugger <[email protected]>

2017-06-23 21:46:40

by Rob Herring (Arm)

[permalink] [raw]
Subject: Re: [PATCH 1/2] spi: mediatek: Add bindings for mediatek MT2712 soc platform

On Tue, Jun 20, 2017 at 04:21:06PM +0800, Leilk Liu wrote:
> This patch adds a DT binding documentation for the MT2712 soc.
>
> Signed-off-by: Leilk Liu <[email protected]>
> ---
> .../devicetree/bindings/spi/spi-mt65xx.txt | 1 +
> 1 file changed, 1 insertion(+)

Acked-by: Rob Herring <[email protected]>