Skip to contentSkip to conversation

Add basic and clock support for Mediatek MT8183 SoC

PATCH Superseded Erin Lo 3 participants 6 messages Mar 18, 2019 – Apr 16, 2019

Subsystems (3)

v9 of 10 Superseded Latest is v10 →

lore
Share & tools
lore

Erin Lo

author
#0 lore raw

PATCH v9 1/1 Add basic and clock support for Mediatek MT8183 SoC

MT8183 is a SoC based on 64bit ARMv8 architecture.
It contains 4 CA53 and 4 CA73 cores.
MT8183 share many HW IP with MT65xx series.
This patchset was tested on MT8183 evaluation board and use correct clock to shell.

Based on v5.1-rc1 and
http://lists.infradead.org/pipermail/linux-mediatek/2019-March/017963.html

Change in v9:
Remove pio node since binding is not documented yet

Change in v8:
1. Fix interrupt-parent of pio node
2. Remove pinfunc.h and spi node patches

Change in v7:
1. Place all the MMIO peripherals under one or more simple-bus nodes
2. Make the pinfunc.h and spi node into seperate patch
3. Modify SPIs pamerater from 4 back to 3
and remove patch "support 4 interrupt parameters for sysirq"
4. Rename intpol-controller to interrupt-controller
5. Rename pinctrl@1000b000 to pinctrl@10005000

Change in v6:
1. Remove power and iommu nodes
2. Fix dtb build warning
3. Fix pinctrl binding doc
4. Fix '_' in node names

Change in v5:
1. Collect all device tree nodes to the last patch
2. Add PMU
3. Add Signed-off-by
4. Remove clock driver code and binding doc
5. Add pinctrl, iommu, spi, and pwrap nodes

Change in v4:
1. Correct syntax error in dtsi
2. Add MT8183 clock support

Change in v3:
1. Fill out GICC, GICH, GICV regions
2. Update Copyright to 2018

Change in v2:
1. Split dt-bindings into different patches
2. Correct bindings for supported SoCs (mtk-uart.txt)

Ben Ho (1):
arm64: dts: Add Mediatek SoC MT8183 and evaluation board dts and
Makefile

 arch/arm64/boot/dts/mediatek/Makefile       |   1 +
 arch/arm64/boot/dts/mediatek/mt8183-evb.dts |  31 +++
 arch/arm64/boot/dts/mediatek/mt8183.dtsi    | 311 ++++++++++++++++++++++++++++
 3 files changed, 343 insertions(+)
 create mode 100644 arch/arm64/boot/dts/mediatek/mt8183-evb.dts
 create mode 100644 arch/arm64/boot/dts/mediatek/mt8183.dtsi

--
1.9.1

author
#1 lore raw

PATCH v9 1/1 arm64: dts: Add Mediatek SoC MT8183 and evaluation board dts and Makefile

From: Ben Ho <[email protected]>

Add basic chip support for Mediatek 8183, include
uart node with correct uart clocks, pwrap device

Add clock controller nodes, include topckgen, infracfg, apmixedsys and subsystem.

---
 arch/arm64/boot/dts/mediatek/Makefile       |   1 +
 arch/arm64/boot/dts/mediatek/mt8183-evb.dts |  31 +++
 arch/arm64/boot/dts/mediatek/mt8183.dtsi    | 311 ++++++++++++++++++++++++++++
 3 files changed, 343 insertions(+)
 create mode 100644 arch/arm64/boot/dts/mediatek/mt8183-evb.dts
 create mode 100644 arch/arm64/boot/dts/mediatek/mt8183.dtsi
arch/arm64/boot/dts/mediatek/Makefile +1 -0
index e8f952f..458bbc4 100644
@@ -7,3 +7,4 @@ dtb-$(CONFIG_ARCH_MEDIATEK) += mt6797-x20-dev.dtb
 dtb-$(CONFIG_ARCH_MEDIATEK) += mt7622-rfb1.dtb
 dtb-$(CONFIG_ARCH_MEDIATEK) += mt7622-bananapi-bpi-r64.dtb
 dtb-$(CONFIG_ARCH_MEDIATEK) += mt8173-evb.dtb
+dtb-$(CONFIG_ARCH_MEDIATEK) += mt8183-evb.dtb
arch/arm64/boot/dts/mediatek/mt8183-evb.dts new file +31 -0
new file mode 100644
index 0000000..9b52559
@@ -0,0 +1,31 @@
+// SPDX-License-Identifier: (GPL-2.0 OR MIT)
+/*
+ * Copyright (c) 2018 MediaTek Inc.
+ * Author: Ben Ho <[email protected]>
+ *	   Erin Lo <[email protected]>
+ */
+
+/dts-v1/;
+#include "mt8183.dtsi"
+
+/ {
+	model = "MediaTek MT8183 evaluation board";
+	compatible = "mediatek,mt8183-evb", "mediatek,mt8183";
+
+	aliases {
+		serial0 = &uart0;
+	};
+
+	memory@40000000 {
+		device_type = "memory";
+		reg = <0 0x40000000 0 0x80000000>;
+	};
+
+	chosen {
+		stdout-path = "serial0:921600n8";
+	};
+};
+
+&uart0 {
+	status = "okay";
+};
arch/arm64/boot/dts/mediatek/mt8183.dtsi new file +311 -0

311 lines not on this page · raw message

Signature · 1 line
1.9.1
#2 lore raw

Re: [PATCH v9] arm64: dts: Add Mediatek SoC MT8183 and evaluation board dts and Makefile

Thank you for the patch! Yet something to improve:

Hi Erin,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on robh/for-next]
[also build test ERROR on v5.1-rc1 next-20190318]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Erin-Lo/arm64-dts-Add-Mediatek-SoC-MT8183-and-evaluation-board-dts-and-Makefile/20190318-170422
base:   https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
config: arm64-allyesconfig (attached as .config)
compiler: aarch64-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0

reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=7.2.0 make.cross ARCH=arm64

All errors (new ones prefixed by >>):

In file included from arch/arm64/boot/dts/mediatek/mt8183-evb.dts:9:0:

>> arch/arm64/boot/dts/mediatek/mt8183.dtsi:8:10: fatal error: dt-bindings/clock/mt8183-clk.h: No such file or directory
    #include <dt-bindings/clock/mt8183-clk.h>
             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

compilation terminated.

vim +8 arch/arm64/boot/dts/mediatek/mt8183.dtsi

   > 8	#include <dt-bindings/clock/mt8183-clk.h>

9 #include <dt-bindings/interrupt-controller/arm-gic.h>
10 #include <dt-bindings/interrupt-controller/irq.h>
11

---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation

maintainer
#3 lore raw

Re: [PATCH v9] arm64: dts: Add Mediatek SoC MT8183 and evaluation board dts and Makefile

Quoted 24 lines · kbuild test robot

Hi Erin,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on robh/for-next]
[also build test ERROR on v5.1-rc1 next-20190318]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Erin-Lo/arm64-dts-Add-Mediatek-SoC-MT8183-and-evaluation-board-dts-and-Makefile/20190318-170422
base:   https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
config: arm64-allyesconfig (attached as .config)
compiler: aarch64-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0

reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=7.2.0 make.cross ARCH=arm64

All errors (new ones prefixed by >>):

   In file included from arch/arm64/boot/dts/mediatek/mt8183-evb.dts:9:0:
Quoted 1 line
Quoted 1 line

arch/arm64/boot/dts/mediatek/mt8183.dtsi:8:10: fatal error: dt-bindings/clock/mt8183-clk.h: No such file or directory

    #include <dt-bindings/clock/mt8183-clk.h>
             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Quoted 9 lines

compilation terminated.

vim +8 arch/arm64/boot/dts/mediatek/mt8183.dtsi

Quoted 1 line

8 #include <dt-bindings/clock/mt8183-clk.h>

9 #include <dt-bindings/interrupt-controller/arm-gic.h>
10 #include <dt-bindings/interrupt-controller/irq.h>
11

Stephen queued the corresponding patch for v5.2.
I propose we wait for v5.2-rc1 and then apply the basic support and the others based on this one.

Erin: There are may mt8183 dts patches floating around that depend on this or more patches. Can you coordinate with your colleagues to resend them as a series? Then it will be easier for me to take them for v5.3, as some have dependencies on other series etc.

Thanks a lot.
Matthias

author
#4 lore raw

Re: [PATCH v9] arm64: dts: Add Mediatek SoC MT8183 and evaluation board dts and Makefile

Quoted 40 lines · Matthias Brugger
Quoted 24 lines · kbuild test robot

Hi Erin,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on robh/for-next]
[also build test ERROR on v5.1-rc1 next-20190318]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Erin-Lo/arm64-dts-Add-Mediatek-SoC-MT8183-and-evaluation-board-dts-and-Makefile/20190318-170422
base:   https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
config: arm64-allyesconfig (attached as .config)
compiler: aarch64-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0

reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=7.2.0 make.cross ARCH=arm64

All errors (new ones prefixed by >>):

   In file included from arch/arm64/boot/dts/mediatek/mt8183-evb.dts:9:0:
Quoted 1 line
Quoted 1 line

arch/arm64/boot/dts/mediatek/mt8183.dtsi:8:10: fatal error: dt-bindings/clock/mt8183-clk.h: No such file or directory

    #include <dt-bindings/clock/mt8183-clk.h>
             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Quoted 9 lines

compilation terminated.

vim +8 arch/arm64/boot/dts/mediatek/mt8183.dtsi

Quoted 1 line

8 #include <dt-bindings/clock/mt8183-clk.h>

9 #include <dt-bindings/interrupt-controller/arm-gic.h>
10 #include <dt-bindings/interrupt-controller/irq.h>
11

Stephen queued the corresponding patch for v5.2.
I propose we wait for v5.2-rc1 and then apply the basic support and the others based on this one.

Quoted 7 lines

Erin: There are may mt8183 dts patches floating around that depend on this or more patches. Can you coordinate with your colleagues to resend them as a series? Then it will be easier for me to take them for v5.3, as some have dependencies on other series etc.

Thanks a lot.
Matthias

OK, I will coordinate with my colleagues to resend mt8183 dts patches as a series base on v5.2-rc1 when v5.2-rc1 release.
Since we want to send this series more confident so they still send separate patch in v5.1 just for review in advance. Is that ok for you?

maintainer
#5 lore raw

Re: [PATCH v9] arm64: dts: Add Mediatek SoC MT8183 and evaluation board dts and Makefile

Quoted 46 lines · Erin Lo
Quoted 45 lines · Matthias Brugger
Quoted 24 lines · kbuild test robot

Hi Erin,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on robh/for-next]
[also build test ERROR on v5.1-rc1 next-20190318]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Erin-Lo/arm64-dts-Add-Mediatek-SoC-MT8183-and-evaluation-board-dts-and-Makefile/20190318-170422
base:   https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
config: arm64-allyesconfig (attached as .config)
compiler: aarch64-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0

reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=7.2.0 make.cross ARCH=arm64

All errors (new ones prefixed by >>):

   In file included from arch/arm64/boot/dts/mediatek/mt8183-evb.dts:9:0:
Quoted 1 line
Quoted 1 line

arch/arm64/boot/dts/mediatek/mt8183.dtsi:8:10: fatal error: dt-bindings/clock/mt8183-clk.h: No such file or directory

    #include <dt-bindings/clock/mt8183-clk.h>
             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Quoted 9 lines

compilation terminated.

vim +8 arch/arm64/boot/dts/mediatek/mt8183.dtsi

Quoted 1 line

8 #include <dt-bindings/clock/mt8183-clk.h>

9 #include <dt-bindings/interrupt-controller/arm-gic.h>
10 #include <dt-bindings/interrupt-controller/irq.h>
11

Stephen queued the corresponding patch for v5.2.
I propose we wait for v5.2-rc1 and then apply the basic support and the others based on this one.

Erin: There are may mt8183 dts patches floating around that depend on this or more patches. Can you coordinate with your colleagues to resend them as a series? Then it will be easier for me to take them for v5.3, as some have dependencies on other series etc.

Quoted 8 lines
Quoted 2 lines

Thanks a lot.
Matthias

OK, I will coordinate with my colleagues to resend mt8183 dts patches as a series base on v5.2-rc1 when v5.2-rc1 release.
Since we want to send this series more confident so they still send separate patch in v5.1 just for review in advance. Is that ok for you?

Sure no problem. Thanks for helping!