mirror of
https://git.openwrt.org/openwrt/openwrt.git
synced 2024-11-22 04:56:15 +00:00
317076d257
This enables the M.2 E-key on ROCK 5A board. Reorder rk356x patch while at it. Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org> Link: https://github.com/openwrt/openwrt/pull/16340 Signed-off-by: Robert Marko <robimarko@gmail.com>
111 lines
3.4 KiB
Diff
111 lines
3.4 KiB
Diff
From b728d4c51f0ce9207daf502f3a85073785c46319 Mon Sep 17 00:00:00 2001
|
|
From: FUKAUMI Naoki <naoki@radxa.com>
|
|
Date: Mon, 26 Aug 2024 17:04:56 +0900
|
|
Subject: [PATCH] arm64: dts: rockchip: enable PCIe on M.2 E key for Radxa ROCK
|
|
5A
|
|
|
|
Enable pcie2x1l2 and related combphy/regulator routed to M.2 E key
|
|
connector on Radxa ROCK 5A.
|
|
|
|
Tested with Radxa Wireless Module A8:
|
|
|
|
$ lspci
|
|
0004:40:00.0 PCI bridge: Rockchip Electronics Co., Ltd RK3588 (rev 01)
|
|
0004:41:00.0 Network controller: Realtek Semiconductor Co., Ltd. RTL8852BE PCIe 802.11ax Wireless Network Controller
|
|
|
|
$ ip l
|
|
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
|
|
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
|
|
2: end0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DEFAULT group default qlen 1000
|
|
link/ether c2:58:fc:70:55:86 brd ff:ff:ff:ff:ff:ff
|
|
3: wlP4p65s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000
|
|
link/ether 2c:05:47:65:5b:ed brd ff:ff:ff:ff:ff:ff
|
|
|
|
$ lsusb
|
|
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
|
|
Bus 001 Device 002: ID 1a40:0101 Terminus Technology Inc. Hub
|
|
Bus 001 Device 003: ID 0bda:b85b Realtek Semiconductor Corp. Bluetooth Radio
|
|
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
|
|
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
|
|
Bus 004 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
|
|
Bus 005 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
|
|
Bus 006 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
|
|
Bus 006 Device 002: ID 0789:0336 Logitec Corp. LMD USB Device
|
|
Bus 007 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
|
|
Bus 008 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
|
|
|
|
$ hciconfig
|
|
hci0: Type: Primary Bus: USB
|
|
BD Address: 2C:05:47:65:5B:EE ACL MTU: 1021:6 SCO MTU: 255:12
|
|
UP RUNNING
|
|
RX bytes:2698 acl:0 sco:0 events:329 errors:0
|
|
TX bytes:69393 acl:0 sco:0 commands:329 errors:0
|
|
|
|
Signed-off-by: FUKAUMI Naoki <naoki@radxa.com>
|
|
Link: https://lore.kernel.org/r/20240826080456.525-1-naoki@radxa.com
|
|
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
|
---
|
|
.../boot/dts/rockchip/rk3588s-rock-5a.dts | 30 +++++++++++++++++++
|
|
1 file changed, 30 insertions(+)
|
|
|
|
--- a/arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts
|
|
+++ b/arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts
|
|
@@ -64,6 +64,18 @@
|
|
regulator-max-microvolt = <12000000>;
|
|
};
|
|
|
|
+ vcc3v3_wf: vcc3v3-wf-regulator {
|
|
+ compatible = "regulator-fixed";
|
|
+ regulator-name = "vcc3v3_wf";
|
|
+ regulator-min-microvolt = <3300000>;
|
|
+ regulator-max-microvolt = <3300000>;
|
|
+ enable-active-high;
|
|
+ gpio = <&gpio0 RK_PC5 GPIO_ACTIVE_HIGH>;
|
|
+ pinctrl-0 = <&pow_en>;
|
|
+ pinctrl-names = "default";
|
|
+ vin-supply = <&vcc5v0_sys>;
|
|
+ };
|
|
+
|
|
vcc5v0_host: vcc5v0-host-regulator {
|
|
compatible = "regulator-fixed";
|
|
regulator-name = "vcc5v0_host";
|
|
@@ -113,6 +125,10 @@
|
|
};
|
|
};
|
|
|
|
+&combphy0_ps {
|
|
+ status = "okay";
|
|
+};
|
|
+
|
|
&combphy2_psu {
|
|
status = "okay";
|
|
};
|
|
@@ -292,6 +308,14 @@
|
|
};
|
|
};
|
|
|
|
+&pcie2x1l2 {
|
|
+ pinctrl-0 = <&pcie20x1m0_pins>;
|
|
+ pinctrl-names = "default";
|
|
+ reset-gpios = <&gpio3 RK_PD1 GPIO_ACTIVE_HIGH>;
|
|
+ vpcie3v3-supply = <&vcc3v3_wf>;
|
|
+ status = "okay";
|
|
+};
|
|
+
|
|
&pinctrl {
|
|
leds {
|
|
io_led: io-led {
|
|
@@ -299,6 +323,12 @@
|
|
};
|
|
};
|
|
|
|
+ pcie {
|
|
+ pow_en: pow-en {
|
|
+ rockchip,pins = <0 RK_PC5 RK_FUNC_GPIO &pcfg_pull_none>;
|
|
+ };
|
|
+ };
|
|
+
|
|
power {
|
|
vcc_5v0_en: vcc-5v0-en {
|
|
rockchip,pins = <4 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>;
|