arm64: dts: rockchip: fix eeprom for Radxa ROCK 5A
Subsystems (2)
PATCH 1/8 arm64: dts: rockchip: fix eeprom for Radxa ROCK 5A
- move eeprom from i2c2 to i2c0 to match with schematic[1]
- add vcc_3v3_pmu regulator and use it as vcc-supply for eeprom
[1] https://dl.radxa.com/rock5/5a/docs/hw/radxa_rock5a_V1.1_sch.pdf
--- .../boot/dts/rockchip/rk3588s-rock-5a.dts | 23 ++++++++++++++----- 1 file changed, 17 insertions(+), 6 deletions(-)
arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts +17 -6
@@ -113,6 +113,16 @@ vcc5v0_sys: regulator-vcc5v0-sys { vin-supply = <&vcc12v_dcin>; }; + vcc_3v3_pmu: regulator-vcc-3v3-pmu { + compatible = "regulator-fixed"; + regulator-name = "vcc_3v3_pmu"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + vin-supply = <&vcc_3v3_s3>; + }; + vcc_5v0: regulator-vcc-5v0 { compatible = "regulator-fixed"; regulator-name = "vcc_5v0";
@@ -221,6 +231,13 @@ regulator-state-mem { regulator-off-in-suspend; }; }; + + eeprom: eeprom@50 { + compatible = "belling,bl24c16a", "atmel,24c16"; + reg = <0x50>; + pagesize = <16>; + vcc-supply = <&vcc_3v3_pmu>; + }; }; &i2c2 {
@@ -242,12 +259,6 @@ regulator-state-mem { regulator-off-in-suspend; }; }; - - eeprom: eeprom@50 { - compatible = "belling,bl24c16a", "atmel,24c16"; - reg = <0x50>; - pagesize = <16>; - }; }; &i2c3 {
Signature · 1 line
2.43.0
PATCH 2/8 arm64: dts: rockchip: remove i2c3 and i2c5 node for Radxa ROCK 5A
currently i2c3 and i2c5 are not used. remove them.
--- arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts | 10 ---------- 1 file changed, 10 deletions(-)
arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts +0 -10
@@ -261,16 +261,6 @@ regulator-state-mem { }; }; -&i2c3 { - status = "okay"; -}; - -&i2c5 { - status = "okay"; - pinctrl-names = "default"; - pinctrl-0 = <&i2c5m2_xfer>; -}; - &i2c7 { status = "okay";
Signature · 1 line
2.43.0
PATCH 3/8 arm64: dts: rockchip: fix sdmmc properties for Radxa ROCK 5A
In reply to FUKAUMI Naoki- remove max-frequency (use default 200MHz) to match with vendor kernel[1]
- fix vmmc-supply to match with schematic[2]
[1] https://github.com/radxa/kernel/blob/linux-6.1-stan-rkr1/arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts
[2] https://dl.radxa.com/rock5/5a/docs/hw/radxa_rock5a_V1.1_sch.pdf
--- arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts +1 -2
@@ -423,11 +423,10 @@ &sdmmc { cap-sd-highspeed; cd-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_LOW>; disable-wp; - max-frequency = <150000000>; no-sdio; no-mmc; sd-uhs-sdr104; - vmmc-supply = <&vcc_3v3_s0>; + vmmc-supply = <&vcc_3v3_s3>; vqmmc-supply = <&vccio_sd_s0>; status = "okay"; };
Signature · 1 line
2.43.0
PATCH 4/8 arm64: dts: rockchip: fix u2phy2_host phy-supply for Radxa ROCK 5A
In reply to FUKAUMI Naokiby schematic[1], USB2.0 HOST0 is connected to USB hub(FE1.1s), and USB hub power is supplied by vcc_5v0.
[1] https://dl.radxa.com/rock5/5a/docs/hw/radxa_rock5a_V1.1_sch.pdf
--- arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts +2 -1
@@ -783,8 +783,9 @@ &u2phy2 { }; &u2phy2_host { + /* connected to USB hub, which is powered by vcc_5v0 */ + phy-supply = <&vcc_5v0>; status = "okay"; - phy-supply = <&vcc5v0_host>; }; &u2phy3 {
Signature · 1 line
2.43.0
PATCH 5/8 arm64: dts: rockchip: remove usb_host0_ohci for Radxa ROCK 5A
In reply to FUKAUMI Naokisince USB hub(FE1.1s) has Transaction Translator, usb_host0_ohci is not used for low/full speed USB device. remove it.
--- arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts | 4 ---- 1 file changed, 4 deletions(-)
arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts +0 -4
@@ -811,10 +811,6 @@ &usb_host0_ehci { status = "okay"; }; -&usb_host0_ohci { - status = "okay"; -}; - &usb_host0_xhci { dr_mode = "host"; status = "okay";
Signature · 1 line
2.43.0
PATCH 6/8 arm64: dts: rockchip: add default-state for heartbeat LED on Radxa ROCK 5A
In reply to FUKAUMI Naokiadd default-state = "on" for heartbeat LED to match with U-Boot[1].
[1] https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/
--- arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts | 1 + 1 file changed, 1 insertion(+)
arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts +1 -0
@@ -54,6 +54,7 @@ leds { io-led { color = <LED_COLOR_ID_BLUE>; + default-state = "on"; function = LED_FUNCTION_STATUS; gpios = <&gpio3 RK_PD5 GPIO_ACTIVE_HIGH>; linux,default-trigger = "heartbeat";
Signature · 1 line
2.43.0
PATCH 7/8 arm64: dts: rockchip: fix pwm-fan property for Radxa ROCK 5A
In reply to FUKAUMI Naokifix pwm period to match with vendor kernel[1].
--- arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts +2 -2
@@ -63,9 +63,9 @@ io-led { fan: pwm-fan { compatible = "pwm-fan"; - cooling-levels = <0 95 145 195 255>; + cooling-levels = <0 64 128 192 255>; fan-supply = <&vcc_5v0>; - pwms = <&pwm3 0 50000 0>; + pwms = <&pwm3 0 60000 0>; #cooling-cells = <2>; };
Signature · 1 line
2.43.0
PATCH 8/8 arm64: dts: rockchip: fix pinctrl pin labels/names for Radxa ROCK 5A
In reply to FUKAUMI Naokifix pinctrl pin labels/names to match with schematic[1].
[1] https://dl.radxa.com/rock5/5a/docs/hw/radxa_rock5a_V1.1_sch.pdf
--- .../boot/dts/rockchip/rk3588s-rock-5a.dts | 38 +++++++++---------- 1 file changed, 19 insertions(+), 19 deletions(-)
arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts +19 -19
@@ -100,7 +100,7 @@ vcc5v0_host: regulator-vcc5v0-host { enable-active-high; gpio = <&gpio4 RK_PB5 GPIO_ACTIVE_HIGH>; pinctrl-names = "default"; - pinctrl-0 = <&vcc5v0_host_en>; + pinctrl-0 = <&usb_host_pwren_h>; vin-supply = <&vcc5v0_sys>; };
@@ -134,7 +134,7 @@ vcc_5v0: regulator-vcc-5v0 { enable-active-high; gpio = <&gpio4 RK_PA3 GPIO_ACTIVE_HIGH>; pinctrl-names = "default"; - pinctrl-0 = <&vcc_5v0_en>; + pinctrl-0 = <&vcc_5v0_pwren_h>; vin-supply = <&vcc5v0_sys>; };
@@ -346,7 +346,7 @@ rgmii_phy1: ethernet-phy@1 { compatible = "ethernet-phy-id001c.c916"; reg = <0x1>; pinctrl-names = "default"; - pinctrl-0 = <&rtl8211f_rst>; + pinctrl-0 = <&gmac1_rstn>; reset-assert-us = <20000>; reset-deassert-us = <100000>; reset-gpios = <&gpio3 RK_PB7 GPIO_ACTIVE_LOW>;
@@ -354,7 +354,9 @@ rgmii_phy1: ethernet-phy@1 { }; &pcie2x1l2 { - pinctrl-0 = <&pcie2_reset>, <&pcie20x1m0_clkreqn>, <&pcie20x1m0_waken>; + pinctrl-0 = <&pcie20x1_2_perstn_m0>, + <&pcie20x1m0_clkreqn>, + <&pcie20x1m0_waken>; pinctrl-names = "default"; reset-gpios = <&gpio3 RK_PD1 GPIO_ACTIVE_HIGH>; vpcie3v3-supply = <&vcc3v3_wf>;
@@ -368,32 +370,30 @@ io_led: io-led { }; }; - pcie { - pow_en: pow-en { - rockchip,pins = <0 RK_PC5 RK_FUNC_GPIO &pcfg_pull_none>; - }; - - pcie2_reset: pcie2-reset { - rockchip,pins = <3 RK_PD1 RK_FUNC_GPIO &pcfg_pull_none>; + mdio { + gmac1_rstn: gmac1-rstn { + rockchip,pins = <3 RK_PB7 RK_FUNC_GPIO &pcfg_pull_none>; }; }; - power { - vcc_5v0_en: vcc-5v0-en { - rockchip,pins = <4 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>; + pcie { + pcie20x1_2_perstn_m0: pcie20x1-2-perstn-m0 { + rockchip,pins = <3 RK_PD1 RK_FUNC_GPIO &pcfg_pull_none>; }; - }; - rtl8211f { - rtl8211f_rst: rtl8211f-rst { - rockchip,pins = <3 RK_PB7 RK_FUNC_GPIO &pcfg_pull_none>; + pow_en: pow-en { + rockchip,pins = <0 RK_PC5 RK_FUNC_GPIO &pcfg_pull_none>; }; }; usb { - vcc5v0_host_en: vcc5v0-host-en { + usb_host_pwren_h: usb-host-pwren-h { rockchip,pins = <4 RK_PB5 RK_FUNC_GPIO &pcfg_pull_none>; }; + + vcc_5v0_pwren_h: vcc-5v0-pwren-h { + rockchip,pins = <4 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>; + }; }; };
Signature · 1 line
2.43.0
Hi,
please ignore this patchset for Radxa ROCK 5A.
ROCK 5C is slightly updated version of ROCK 5A, and they are 99% identical from the perspective of device tree.
(if you want, you can use rk3588s-rock-5c.dts(dtb) for ROCK 5A)
I'll update ROCK 5C patchset to make commin .dtsi, then convert both ROCK 5A and 5C dts to use common (and up-to-date) .dtsi.
Best regards,
--
FUKAUMI Naoki
Radxa Computer (Shenzhen) Co., Ltd.
Quoted 58 lines · FUKAUMI Naoki
- move eeprom from i2c2 to i2c0 to match with schematic[1]
- addvcc_3v3_pmuregulator and use it as vcc-supply for eeprom[1] https://dl.radxa.com/rock5/5a/docs/hw/radxa_rock5a_V1.1_sch.pdf
Signed-off-by FUKAUMI Naoki <[email protected]>--- .../boot/dts/rockchip/rk3588s-rock-5a.dts | 23 ++++++++++++++----- 1 file changed, 17 insertions(+), 6 deletions(-)arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts +17
-6@@ -113,6 +113,16 @@ vcc5v0_sys: regulator-vcc5v0-sys { vin-supply = <&vcc12v_dcin>; }; + vcc_3v3_pmu: regulator-vcc-3v3-pmu { + compatible = "regulator-fixed"; + regulator-name = "vcc_3v3_pmu"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + vin-supply = <&vcc_3v3_s3>; + }; + vcc_5v0: regulator-vcc-5v0 { compatible = "regulator-fixed"; regulator-name = "vcc_5v0";@@ -221,6 +231,13 @@ regulator-state-mem { regulator-off-in-suspend; }; }; + + eeprom: eeprom@50 { + compatible = "belling,bl24c16a", "atmel,24c16"; + reg = <0x50>; + pagesize = <16>; + vcc-supply = <&vcc_3v3_pmu>; + }; }; &i2c2 {@@ -242,12 +259,6 @@ regulator-state-mem { regulator-off-in-suspend; }; }; - - eeprom: eeprom@50 { - compatible = "belling,bl24c16a", "atmel,24c16"; - reg = <0x50>; - pagesize = <16>; - }; }; &i2c3 {