Skip to contentSkip to conversation

Add basic node support for MediaTek MT8188 SoC

PATCH Superseded Jason-ch Chen 3 participants 9 messages Jul 18, 2023 – Jul 19, 2023

Subsystems (2)

v4 of 6 Superseded Latest is v6 →

lore
Share & tools
lore
#0 lore raw

v4 cover Add basic node support for MediaTek MT8188 SoC

From: jason-ch chen <[email protected]>

MT8188 is a SoC based on 64bit ARMv8 architecture. It contains 6 CA55 and 2 CA78 cores. MT8188 share many HW IP with MT65xx series.

This patchset was tested on MT8188 evaluation board to shell.

Based on tag: next-20230718, linux-next/master

Changes in v4:
- Explain the reason of modifying pwrap binding file, and correct the subject
- Fix reviewer's comments

Changes in v3:
- Remove the duplicated part of mt8188 in the pwrap yaml file
- Fix reviewer's comments about coding style

Changes in v2:
- Add MT8188 PMIC Wrapper compatible to binding document
- Fix reviewer's comments

jason-ch chen (4):
dt-bindings: arm: Add compatible for MediaTek MT8188
dt-bindings: arm: mediatek: Add mt8188 pericfg compatible
dt-bindings: soc: mediatek: pwrap: Modify compatible for MT8188
arm64: dts: Add MediaTek MT8188 dts and evaluation board and Makefile

 .../devicetree/bindings/arm/mediatek.yaml     |   4 +
 .../arm/mediatek/mediatek,pericfg.yaml        |   1 +
 .../bindings/soc/mediatek/mediatek,pwrap.yaml |   6 +-
 arch/arm64/boot/dts/mediatek/Makefile         |   1 +
 arch/arm64/boot/dts/mediatek/mt8188-evb.dts   | 400 ++++++++
 arch/arm64/boot/dts/mediatek/mt8188.dtsi      | 951 ++++++++++++++++++
 6 files changed, 1362 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm64/boot/dts/mediatek/mt8188-evb.dts
 create mode 100644 arch/arm64/boot/dts/mediatek/mt8188.dtsi
Signature · 1 line
2.18.0
#1 lore raw

PATCH v4 1/4 dt-bindings: arm: Add compatible for MediaTek MT8188

From: jason-ch chen <[email protected]>

This commit adds dt-binding documentation for the MediaTek MT8188 reference board.

---
 Documentation/devicetree/bindings/arm/mediatek.yaml | 4 ++++
 1 file changed, 4 insertions(+)
Documentation/devicetree/bindings/arm/mediatek.yaml +4 -0
index ae12b1cab9fb..4f4910d7a1e9 100644
@@ -163,6 +163,10 @@ properties:
           - enum:
               - mediatek,mt8186-evb
           - const: mediatek,mt8186
+      - items:
+          - enum:
+              - mediatek,mt8188-evb
+          - const: mediatek,mt8188
       - items:
           - enum:
               - mediatek,mt8192-evb
Signature · 1 line
2.18.0
#2 lore raw

PATCH v4 2/4 dt-bindings: arm: mediatek: Add mt8188 pericfg compatible

In reply to Jason-ch Chen

From: jason-ch chen <[email protected]>

Add mt8188 pericfg compatible to binding document.

---
 .../devicetree/bindings/arm/mediatek/mediatek,pericfg.yaml       | 1 +
 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/arm/mediatek/mediatek,pericfg.yaml +1 -0
index 26158d0d72f3..33c94c491828 100644
@@ -28,6 +28,7 @@ properties:
               - mediatek,mt8173-pericfg
               - mediatek,mt8183-pericfg
               - mediatek,mt8186-pericfg
+              - mediatek,mt8188-pericfg
               - mediatek,mt8195-pericfg
               - mediatek,mt8516-pericfg
           - const: syscon
Signature · 1 line
2.18.0
#3 lore raw

PATCH v4 3/4 dt-bindings: soc: mediatek: pwrap: Modify compatible for MT8188

In reply to Jason-ch Chen

From: jason-ch chen <[email protected]>

The reason for changing the patch was that while MT8188 uses the same pwrap as MT8195, the original code was only applicable to 'compatible = "mediatek,mt8188-pwrap"'. To resolve the DTBS check warning that '['mediatek,mt8188-pwrap', 'mediatek,mt8195-pwrap', 'syscon'] is too long', it is necessary to modify the code.

---
 .../devicetree/bindings/soc/mediatek/mediatek,pwrap.yaml    | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
Documentation/devicetree/bindings/soc/mediatek/mediatek,pwrap.yaml +5 -1
index a06ac2177444..4737e5f45d54 100644
@@ -41,7 +41,6 @@ properties:
               - mediatek,mt8173-pwrap
               - mediatek,mt8183-pwrap
               - mediatek,mt8186-pwrap
-              - mediatek,mt8188-pwrap
               - mediatek,mt8195-pwrap
               - mediatek,mt8365-pwrap
               - mediatek,mt8516-pwrap
@@ -50,6 +49,11 @@ properties:
               - mediatek,mt8186-pwrap
               - mediatek,mt8195-pwrap
           - const: syscon
+      - items:
+          - enum:
+              - mediatek,mt8188-pwrap
+          - const: mediatek,mt8195-pwrap
+          - const: syscon
 
   reg:
     minItems: 1
Signature · 1 line
2.18.0
Acked-by on v4 3/4
#4 lore raw

Re: [PATCH v4 3/4] dt-bindings: soc: mediatek: pwrap: Modify compatible for MT8188

Quoted 7 lines · Jason-ch Chen

From: jason-ch chen <[email protected]>

The reason for changing the patch was that while MT8188 uses the same pwrap as MT8195,

the original code was only applicable to 'compatible = "mediatek,mt8188-pwrap"'.

I don't really understand what this means. Did you mean, "the original binding only allowed..."? If so,

Thanks,
Conor.

Quoted 36 lines

To resolve the DTBS check warning that '['mediatek,mt8188-pwrap', 'mediatek,mt8195-pwrap', 'syscon'] is too long', it is necessary to modify the code.

---
 .../devicetree/bindings/soc/mediatek/mediatek,pwrap.yaml    | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
Documentation/devicetree/bindings/soc/mediatek/mediatek,pwrap.yaml +5 -1
index a06ac2177444..4737e5f45d54 100644
@@ -41,7 +41,6 @@ properties:
               - mediatek,mt8173-pwrap
               - mediatek,mt8183-pwrap
               - mediatek,mt8186-pwrap
-              - mediatek,mt8188-pwrap
               - mediatek,mt8195-pwrap
               - mediatek,mt8365-pwrap
               - mediatek,mt8516-pwrap
@@ -50,6 +49,11 @@ properties:
               - mediatek,mt8186-pwrap
               - mediatek,mt8195-pwrap
           - const: syscon
+      - items:
+          - enum:
+              - mediatek,mt8188-pwrap
+          - const: mediatek,mt8195-pwrap
+          - const: syscon
 
   reg:
     minItems: 1
Signature · 1 line
2.18.0
#5 lore raw

Re: [PATCH v4 3/4] dt-bindings: soc: mediatek: pwrap: Modify compatible for MT8188

Hi Conor,

Quoted 9 lines · Conor Dooley
Quoted 7 lines · Jason-ch Chen

From: jason-ch chen <[email protected]>

The reason for changing the patch was that while MT8188 uses the same
pwrap as MT8195,
the original code was only applicable to 'compatible = "mediatek,mt8188-pwrap"'.

Quoted 5 lines

I don't really understand what this means. Did you mean, "the original
binding only allowed..."? If so,

Thank you for your reply.
The actual test results confirm that the original binding is only allowed to 'compatible = "mediatek,mt8188-pwrap"'.

Quoted 44 lines

Thanks,
Conor.

Quoted 41 lines

To resolve the DTBS check warning that '['mediatek,mt8188-pwrap', 'mediatek,mt8195-pwrap', 'syscon'] is too
long', it is necessary to modify the code.

---
 .../devicetree/bindings/soc/mediatek/mediatek,pwrap.yaml    | 6
+++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/soc/mediatek/mediatek,pwrap.yam l b/Documentation/devicetree/bindings/soc/mediatek/mediatek,pwrap.yam l
index a06ac2177444..4737e5f45d54 100644
---
a/Documentation/devicetree/bindings/soc/mediatek/mediatek,pwrap.yam l
+++
b/Documentation/devicetree/bindings/soc/mediatek/mediatek,pwrap.yam l

Documentation/devicetree/bindings/soc/mediatek/mediatek,pwrap.yaml +5 -1
@@ -41,7 +41,6 @@ properties:
               - mediatek,mt8173-pwrap
               - mediatek,mt8183-pwrap
               - mediatek,mt8186-pwrap
-              - mediatek,mt8188-pwrap
               - mediatek,mt8195-pwrap
               - mediatek,mt8365-pwrap
               - mediatek,mt8516-pwrap
@@ -50,6 +49,11 @@ properties:
               - mediatek,mt8186-pwrap
               - mediatek,mt8195-pwrap
           - const: syscon
+      - items:
+          - enum:
+              - mediatek,mt8188-pwrap
+          - const: mediatek,mt8195-pwrap
+          - const: syscon
 
Quoted 4 lines
Quoted 4 lines
Documentation/devicetree/bindings/soc/mediatek/mediatek,pwrap.yaml +0 -0
   reg:
     minItems: 1
Signature · 1 line
2.18.0

Regards,
Jason

maintainer Reviewed-by on v4 3/4
#6 lore raw

Re: [PATCH v4 3/4] dt-bindings: soc: mediatek: pwrap: Modify compatible for MT8188

In reply to Jason-ch Chen

Il 18/07/23 13:09, Jason-ch Chen ha scritto:

Quoted 9 lines

From: jason-ch chen <[email protected]>

The reason for changing the patch was that while MT8188 uses the same pwrap as MT8195, the original code was only applicable to 'compatible = "mediatek,mt8188-pwrap"'. To resolve the DTBS check warning that '['mediatek,mt8188-pwrap', 'mediatek,mt8195-pwrap', 'syscon'] is too long', it is necessary to modify the code.

The original binding allowed only "mediatek,mt8188-pwrap", while we need to specify

compatible = "mediatek,mt8188-pwrap", "mediatek,mt8195-pwrap", "syscon";

for this node, as MT8188's PWRAP is fully compatible with MT8195 as it is the very same IP, hence:

Regards,
Angelo

Quoted 28 lines
---
  .../devicetree/bindings/soc/mediatek/mediatek,pwrap.yaml    | 6 +++++-
  1 file changed, 5 insertions(+), 1 deletion(-)
Documentation/devicetree/bindings/soc/mediatek/mediatek,pwrap.yaml +5 -1
index a06ac2177444..4737e5f45d54 100644
@@ -41,7 +41,6 @@ properties:
                - mediatek,mt8173-pwrap
                - mediatek,mt8183-pwrap
                - mediatek,mt8186-pwrap
-              - mediatek,mt8188-pwrap
                - mediatek,mt8195-pwrap
                - mediatek,mt8365-pwrap
                - mediatek,mt8516-pwrap
@@ -50,6 +49,11 @@ properties:
                - mediatek,mt8186-pwrap
                - mediatek,mt8195-pwrap
            - const: syscon
+      - items:
+          - enum:
+              - mediatek,mt8188-pwrap
+          - const: mediatek,mt8195-pwrap
+          - const: syscon
 
    reg:
      minItems: 1
#7 lore raw

PATCH v4 4/4 arm64: dts: Add MediaTek MT8188 dts and evaluation board and Makefile

In reply to Jason-ch Chen

From: jason-ch chen <[email protected]>

MT8188 is a SoC based on 64bit ARMv8 architecture. It contains 6 CA55 and 2 CA78 cores. MT8188 share many HW IP with MT65xx series.

We add basic chip support for MediaTek MT8188 on evaluation board.

---
 arch/arm64/boot/dts/mediatek/Makefile       |   1 +
 arch/arm64/boot/dts/mediatek/mt8188-evb.dts | 400 ++++++++
 arch/arm64/boot/dts/mediatek/mt8188.dtsi    | 951 ++++++++++++++++++++
 3 files changed, 1352 insertions(+)
 create mode 100644 arch/arm64/boot/dts/mediatek/mt8188-evb.dts
 create mode 100644 arch/arm64/boot/dts/mediatek/mt8188.dtsi
arch/arm64/boot/dts/mediatek/Makefile +1 -0
index c99c3372a4b5..9bd2324259a3 100644
@@ -44,6 +44,7 @@ dtb-$(CONFIG_ARCH_MEDIATEK) += mt8183-kukui-krane-sku0.dtb
 dtb-$(CONFIG_ARCH_MEDIATEK) += mt8183-kukui-krane-sku176.dtb
 dtb-$(CONFIG_ARCH_MEDIATEK) += mt8183-pumpkin.dtb
 dtb-$(CONFIG_ARCH_MEDIATEK) += mt8186-evb.dtb
+dtb-$(CONFIG_ARCH_MEDIATEK) += mt8188-evb.dtb
 dtb-$(CONFIG_ARCH_MEDIATEK) += mt8192-asurada-hayato-r1.dtb
 dtb-$(CONFIG_ARCH_MEDIATEK) += mt8192-asurada-spherion-r0.dtb
 dtb-$(CONFIG_ARCH_MEDIATEK) += mt8192-evb.dtb
arch/arm64/boot/dts/mediatek/mt8188-evb.dts new file +400 -0

400 lines not on this page · raw message

arch/arm64/boot/dts/mediatek/mt8188.dtsi new file +951 -0

951 lines not on this page · raw message

Signature · 1 line
2.18.0
maintainer Reviewed-by on v4 4/4
#8 lore raw

Re: [PATCH v4 4/4] arm64: dts: Add MediaTek MT8188 dts and evaluation board and Makefile

Il 18/07/23 13:09, Jason-ch Chen ha scritto:

Quoted 8 lines

From: jason-ch chen <[email protected]>

MT8188 is a SoC based on 64bit ARMv8 architecture. It contains 6 CA55 and 2 CA78 cores. MT8188 share many HW IP with MT65xx series.

We add basic chip support for MediaTek MT8188 on evaluation board.