Skip to content

Commit 332a1ff

Browse files
committed
Merge tag 'spacemit-dt-for-6.20-1' of https://github.com/spacemit-com/linux into soc/dt
RISC-V SpacemiT DT changes for 6.20 - Disable Ethernet PHY auto sleep mode - Add pinctrl IO power support - Add K3 Pico-ITX board - Add support for K3 SoC - Add DWC USB support - Add reset for eMMC(sdhci)/I2C - Add PCIe support - Support PMIC for Jupiter board * tag 'spacemit-dt-for-6.20-1' of https://github.com/spacemit-com/linux: riscv: dts: spacemit: Disable ETH PHY sleep mode for OrangePi riscv: dts: spacemit: pinctrl: update register and IO power riscv: dts: spacemit: add K3 Pico-ITX board support riscv: dts: spacemit: add initial support for K3 SoC dt-bindings: riscv: spacemit: add K3 and Pico-ITX board bindings dt-bindings: interrupt-controller: add SpacemiT K3 IMSIC dt-bindings: interrupt-controller: add SpacemiT K3 APLIC dt-bindings: timer: add SpacemiT K3 CLINT dt-bindings: riscv: add SpacemiT X100 CPU compatible riscv: dts: spacemit: k1: Add "b" ISA extension riscv: dts: spacemit: Enable USB3.0 on BananaPi-F3 riscv: dts: spacemit: Add DWC3 USB 3.0 controller node for K1 riscv: dts: spacemit: Add USB2 PHY node for K1 riscv: dts: spacemit: sdhci: add reset support riscv: dts: spacemit: add reset property riscv: dts: spacemit: PCIe and PHY-related updates riscv: dts: spacemit: Add a PCIe regulator riscv: dts: spacemit: Define the P1 PMIC regulators for Milk-V Jupiter riscv: dts: spacemit: Define fixed regulators for Milk-V Jupiter riscv: dts: spacemit: Enable i2c8 adapter for Milk-V Jupiter Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2 parents c8f7de0 + 5164e95 commit 332a1ff

14 files changed

Lines changed: 1116 additions & 17 deletions

File tree

Documentation/devicetree/bindings/interrupt-controller/riscv,aplic.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ properties:
2828
items:
2929
- enum:
3030
- qemu,aplic
31+
- spacemit,k3-aplic
3132
- const: riscv,aplic
3233

3334
reg:

Documentation/devicetree/bindings/interrupt-controller/riscv,imsics.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ properties:
4848
items:
4949
- enum:
5050
- qemu,imsics
51+
- spacemit,k3-imsics
5152
- const: riscv,imsics
5253

5354
reg:

Documentation/devicetree/bindings/riscv/cpus.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ properties:
6161
- sifive,u7
6262
- sifive,u74
6363
- sifive,u74-mc
64+
- spacemit,x100
6465
- spacemit,x60
6566
- thead,c906
6667
- thead,c908

Documentation/devicetree/bindings/riscv/spacemit.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ $schema: http://devicetree.org/meta-schemas/core.yaml#
77
title: SpacemiT SoC-based boards
88

99
maintainers:
10+
- Guodong Xu <guodong@riscstar.com>
1011
- Yangyu Chen <cyy@cyyself.name>
1112
- Yixun Lan <dlan@gentoo.org>
1213

@@ -26,6 +27,10 @@ properties:
2627
- xunlong,orangepi-r2s
2728
- xunlong,orangepi-rv2
2829
- const: spacemit,k1
30+
- items:
31+
- enum:
32+
- spacemit,k3-pico-itx
33+
- const: spacemit,k3
2934

3035
additionalProperties: true
3136

Documentation/devicetree/bindings/timer/sifive,clint.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ properties:
3333
- eswin,eic7700-clint # ESWIN EIC7700
3434
- sifive,fu540-c000-clint # SiFive FU540
3535
- spacemit,k1-clint # SpacemiT K1
36+
- spacemit,k3-clint # SpacemiT K3
3637
- starfive,jh7100-clint # StarFive JH7100
3738
- starfive,jh7110-clint # StarFive JH7110
3839
- starfive,jh8100-clint # StarFive JH8100

arch/riscv/boot/dts/spacemit/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,4 @@ dtb-$(CONFIG_ARCH_SPACEMIT) += k1-milkv-jupiter.dtb
44
dtb-$(CONFIG_ARCH_SPACEMIT) += k1-musepi-pro.dtb
55
dtb-$(CONFIG_ARCH_SPACEMIT) += k1-orangepi-r2s.dtb
66
dtb-$(CONFIG_ARCH_SPACEMIT) += k1-orangepi-rv2.dtb
7+
dtb-$(CONFIG_ARCH_SPACEMIT) += k3-pico-itx.dtb

arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,14 @@
3333
};
3434
};
3535

36+
pcie_vcc_3v3: pcie-vcc3v3 {
37+
compatible = "regulator-fixed";
38+
regulator-name = "PCIE_VCC3V3";
39+
regulator-min-microvolt = <3300000>;
40+
regulator-max-microvolt = <3300000>;
41+
regulator-always-on;
42+
};
43+
3644
reg_dc_in: dc-in-12v {
3745
compatible = "regulator-fixed";
3846
regulator-name = "dc_in_12v";
@@ -51,6 +59,31 @@
5159
regulator-always-on;
5260
vin-supply = <&reg_dc_in>;
5361
};
62+
63+
usb3-vbus-5v {
64+
compatible = "regulator-fixed";
65+
regulator-name = "USB30_VBUS";
66+
regulator-min-microvolt = <5000000>;
67+
regulator-max-microvolt = <5000000>;
68+
regulator-always-on;
69+
gpio = <&gpio K1_GPIO(97) GPIO_ACTIVE_HIGH>;
70+
enable-active-high;
71+
};
72+
73+
usb3_hub_5v: usb3-hub-5v {
74+
compatible = "regulator-fixed";
75+
regulator-name = "USB30_HUB";
76+
regulator-min-microvolt = <5000000>;
77+
regulator-max-microvolt = <5000000>;
78+
gpio = <&gpio K1_GPIO(123) GPIO_ACTIVE_HIGH>;
79+
enable-active-high;
80+
};
81+
};
82+
83+
&combo_phy {
84+
pinctrl-names = "default";
85+
pinctrl-0 = <&pcie0_3_cfg>;
86+
status = "okay";
5487
};
5588

5689
&emmc {
@@ -264,8 +297,65 @@
264297
};
265298
};
266299

300+
&pcie1_phy {
301+
pinctrl-names = "default";
302+
pinctrl-0 = <&pcie1_3_cfg>;
303+
status = "okay";
304+
};
305+
306+
&pcie1_port {
307+
phys = <&pcie1_phy>;
308+
};
309+
310+
&pcie1 {
311+
vpcie3v3-supply = <&pcie_vcc_3v3>;
312+
status = "okay";
313+
};
314+
315+
&pcie2_phy {
316+
pinctrl-names = "default";
317+
pinctrl-0 = <&pcie2_4_cfg>;
318+
status = "okay";
319+
};
320+
321+
&pcie2_port {
322+
phys = <&pcie2_phy>;
323+
};
324+
325+
&pcie2 {
326+
vpcie3v3-supply = <&pcie_vcc_3v3>;
327+
status = "okay";
328+
};
329+
267330
&uart0 {
268331
pinctrl-names = "default";
269332
pinctrl-0 = <&uart0_2_cfg>;
270333
status = "okay";
271334
};
335+
336+
&usbphy2 {
337+
status = "okay";
338+
};
339+
340+
&usb_dwc3 {
341+
dr_mode = "host";
342+
#address-cells = <1>;
343+
#size-cells = <0>;
344+
status = "okay";
345+
346+
hub_2_0: hub@1 {
347+
compatible = "usb2109,2817";
348+
reg = <0x1>;
349+
vdd-supply = <&usb3_hub_5v>;
350+
peer-hub = <&hub_3_0>;
351+
reset-gpios = <&gpio K1_GPIO(124) GPIO_ACTIVE_LOW>;
352+
};
353+
354+
hub_3_0: hub@2 {
355+
compatible = "usb2109,817";
356+
reg = <0x2>;
357+
vdd-supply = <&usb3_hub_5v>;
358+
peer-hub = <&hub_2_0>;
359+
reset-gpios = <&gpio K1_GPIO(124) GPIO_ACTIVE_LOW>;
360+
};
361+
};

arch/riscv/boot/dts/spacemit/k1-milkv-jupiter.dts

Lines changed: 135 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,25 @@
2020
chosen {
2121
stdout-path = "serial0";
2222
};
23+
24+
reg_dc_in: dc-in-12v {
25+
compatible = "regulator-fixed";
26+
regulator-name = "dc_in_12v";
27+
regulator-min-microvolt = <12000000>;
28+
regulator-max-microvolt = <12000000>;
29+
regulator-boot-on;
30+
regulator-always-on;
31+
};
32+
33+
reg_vcc_4v: vcc-4v {
34+
compatible = "regulator-fixed";
35+
regulator-name = "vcc_4v";
36+
regulator-min-microvolt = <4000000>;
37+
regulator-max-microvolt = <4000000>;
38+
regulator-boot-on;
39+
regulator-always-on;
40+
vin-supply = <&reg_dc_in>;
41+
};
2342
};
2443

2544
&eth0 {
@@ -72,6 +91,122 @@
7291
status = "okay";
7392
};
7493

94+
&i2c8 {
95+
pinctrl-0 = <&i2c8_cfg>;
96+
pinctrl-names = "default";
97+
status = "okay";
98+
99+
pmic@41 {
100+
compatible = "spacemit,p1";
101+
reg = <0x41>;
102+
interrupts = <64>;
103+
vin-supply = <&reg_vcc_4v>;
104+
105+
regulators {
106+
buck1 {
107+
regulator-min-microvolt = <500000>;
108+
regulator-max-microvolt = <3450000>;
109+
regulator-ramp-delay = <5000>;
110+
regulator-always-on;
111+
};
112+
113+
buck2 {
114+
regulator-min-microvolt = <500000>;
115+
regulator-max-microvolt = <3450000>;
116+
regulator-ramp-delay = <5000>;
117+
regulator-always-on;
118+
};
119+
120+
buck3_1v8: buck3 {
121+
regulator-min-microvolt = <500000>;
122+
regulator-max-microvolt = <1800000>;
123+
regulator-ramp-delay = <5000>;
124+
regulator-always-on;
125+
};
126+
127+
buck4 {
128+
regulator-min-microvolt = <500000>;
129+
regulator-max-microvolt = <3300000>;
130+
regulator-ramp-delay = <5000>;
131+
regulator-always-on;
132+
};
133+
134+
buck5 {
135+
regulator-min-microvolt = <500000>;
136+
regulator-max-microvolt = <3450000>;
137+
regulator-ramp-delay = <5000>;
138+
regulator-always-on;
139+
};
140+
141+
buck6 {
142+
regulator-min-microvolt = <500000>;
143+
regulator-max-microvolt = <3450000>;
144+
regulator-ramp-delay = <5000>;
145+
regulator-always-on;
146+
};
147+
148+
aldo1 {
149+
regulator-min-microvolt = <500000>;
150+
regulator-max-microvolt = <3400000>;
151+
regulator-boot-on;
152+
};
153+
154+
aldo2 {
155+
regulator-min-microvolt = <500000>;
156+
regulator-max-microvolt = <3400000>;
157+
};
158+
159+
aldo3 {
160+
regulator-min-microvolt = <500000>;
161+
regulator-max-microvolt = <3400000>;
162+
};
163+
164+
aldo4 {
165+
regulator-min-microvolt = <500000>;
166+
regulator-max-microvolt = <3400000>;
167+
};
168+
169+
dldo1 {
170+
regulator-min-microvolt = <500000>;
171+
regulator-max-microvolt = <3400000>;
172+
regulator-boot-on;
173+
};
174+
175+
dldo2 {
176+
regulator-min-microvolt = <500000>;
177+
regulator-max-microvolt = <3400000>;
178+
};
179+
180+
dldo3 {
181+
regulator-min-microvolt = <500000>;
182+
regulator-max-microvolt = <3400000>;
183+
};
184+
185+
dldo4 {
186+
regulator-min-microvolt = <500000>;
187+
regulator-max-microvolt = <3400000>;
188+
regulator-always-on;
189+
};
190+
191+
dldo5 {
192+
regulator-min-microvolt = <500000>;
193+
regulator-max-microvolt = <3400000>;
194+
};
195+
196+
dldo6 {
197+
regulator-min-microvolt = <500000>;
198+
regulator-max-microvolt = <3400000>;
199+
regulator-always-on;
200+
};
201+
202+
dldo7 {
203+
regulator-min-microvolt = <500000>;
204+
regulator-max-microvolt = <3400000>;
205+
};
206+
};
207+
};
208+
};
209+
75210
&uart0 {
76211
pinctrl-names = "default";
77212
pinctrl-0 = <&uart0_2_cfg>;

arch/riscv/boot/dts/spacemit/k1-orangepi-r2s.dts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@
5252

5353
rgmii0: phy@1 {
5454
reg = <0x1>;
55+
motorcomm,auto-sleep-disabled;
5556
};
5657
};
5758
};
@@ -75,6 +76,7 @@
7576

7677
rgmii1: phy@1 {
7778
reg = <0x1>;
79+
motorcomm,auto-sleep-disabled;
7880
};
7981
};
8082
};

arch/riscv/boot/dts/spacemit/k1-orangepi-rv2.dts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@
5454

5555
rgmii0: phy@1 {
5656
reg = <0x1>;
57+
motorcomm,auto-sleep-disabled;
5758
};
5859
};
5960
};
@@ -77,6 +78,7 @@
7778

7879
rgmii1: phy@1 {
7980
reg = <0x1>;
81+
motorcomm,auto-sleep-disabled;
8082
};
8183
};
8284
};

0 commit comments

Comments
 (0)