From 928e9e1d027d5946b83e49755246ecac388e6592 Mon Sep 17 00:00:00 2001 From: Stephen Chen Date: Thu, 28 Nov 2024 18:20:59 +0800 Subject: [PATCH 1/5] feat: add rk3576 overlay Signed-off-by: Stephen Chen --- .../arm64/boot/dts/rockchip/overlays/Makefile | 26 ++++++++++++++++- .../dts/rockchip/overlays/rk3576-can1-m1.dts | 23 +++++++++++++++ .../dts/rockchip/overlays/rk3576-can1-m3.dts | 23 +++++++++++++++ .../dts/rockchip/overlays/rk3576-i2c5-m1.dts | 19 +++++++++++++ .../dts/rockchip/overlays/rk3576-i2c6-m3.dts | 19 +++++++++++++ .../dts/rockchip/overlays/rk3576-i2c8-m1.dts | 19 +++++++++++++ .../dts/rockchip/overlays/rk3576-i2c8-m2.dts | 19 +++++++++++++ .../dts/rockchip/overlays/rk3576-i2c9-m1.dts | 19 +++++++++++++ .../rockchip/overlays/rk3576-pwm0-ch0-m1.dts | 18 ++++++++++++ .../rockchip/overlays/rk3576-pwm1-ch0-m1.dts | 18 ++++++++++++ .../rockchip/overlays/rk3576-pwm1-ch0-m2.dts | 18 ++++++++++++ .../rockchip/overlays/rk3576-pwm1-ch1-m1.dts | 18 ++++++++++++ .../rockchip/overlays/rk3576-pwm1-ch2-m1.dts | 18 ++++++++++++ .../rockchip/overlays/rk3576-pwm1-ch3-m1.dts | 18 ++++++++++++ .../rockchip/overlays/rk3576-pwm1-ch4-m1.dts | 18 ++++++++++++ .../rockchip/overlays/rk3576-pwm2-ch2-m1.dts | 18 ++++++++++++ .../rockchip/overlays/rk3576-pwm2-ch3-m1.dts | 18 ++++++++++++ .../rockchip/overlays/rk3576-pwm2-ch7-m2.dts | 18 ++++++++++++ .../overlays/rk3576-spi1-m0-cs0-spidev.dts | 28 +++++++++++++++++++ .../overlays/rk3576-spi1-m0-cs1-spidev.dts | 28 +++++++++++++++++++ .../overlays/rk3576-spi2-m1-cs0-spidev.dts | 28 +++++++++++++++++++ .../overlays/rk3576-spi2-m1-cs1-spidev.dts | 28 +++++++++++++++++++ .../dts/rockchip/overlays/rk3576-uart2-m0.dts | 19 +++++++++++++ .../dts/rockchip/overlays/rk3576-uart3-m2.dts | 19 +++++++++++++ .../dts/rockchip/overlays/rk3576-uart4-m1.dts | 19 +++++++++++++ .../dts/rockchip/overlays/rk3576-uart7-m0.dts | 19 +++++++++++++ 26 files changed, 534 insertions(+), 1 deletion(-) create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m3.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c5-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c6-m3.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m2.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c9-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm0-ch0-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m2.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch1-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch2-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch3-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch4-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch2-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch3-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch7-m2.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs0-spidev.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs1-spidev.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs0-spidev.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs1-spidev.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-uart2-m0.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-uart3-m2.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-uart4-m1.dts create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3576-uart7-m0.dts diff --git a/arch/arm64/boot/dts/rockchip/overlays/Makefile b/arch/arm64/boot/dts/rockchip/overlays/Makefile index 0f87a4a7..de241e26 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/Makefile +++ b/arch/arm64/boot/dts/rockchip/overlays/Makefile @@ -342,7 +342,31 @@ dtb-$(CONFIG_CPU_RK3568) += \ rock-3c-radxa-display-10hd.dtbo dtb-$(CONFIG_CLK_RK3576) += \ - + rk3576-can1-m1.dtbo \ + rk3576-can1-m3.dtbo \ + rk3576-i2c5-m1.dtbo \ + rk3576-i2c6-m3.dtbo \ + rk3576-i2c8-m1.dtbo \ + rk3576-i2c8-m2.dtbo \ + rk3576-i2c9-m1.dtbo \ + rk3576-pwm0-ch0-m1.dtbo \ + rk3576-pwm1-ch0-m1.dtbo \ + rk3576-pwm1-ch0-m2.dtbo \ + rk3576-pwm1-ch1-m1.dtbo \ + rk3576-pwm1-ch2-m1.dtbo \ + rk3576-pwm1-ch3-m1.dtbo \ + rk3576-pwm1-ch4-m1.dtbo \ + rk3576-pwm2-ch2-m1.dtbo \ + rk3576-pwm2-ch3-m1.dtbo \ + rk3576-pwm2-ch7-m2.dtbo \ + rk3576-spi1-m0-cs0-spidev.dtbo \ + rk3576-spi1-m0-cs1-spidev.dtbo \ + rk3576-spi2-m1-cs0-spidev.dtbo \ + rk3576-spi2-m1-cs1-spidev.dtbo \ + rk3576-uart2-m0.dtbo \ + rk3576-uart3-m2.dtbo \ + rk3576-uart4-m1.dtbo \ + rk3576-uart7-m0.dtbo dtb-$(CONFIG_CPU_RK3576) += \ diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m1.dts new file mode 100644 index 00000000..40605b1b --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m1.dts @@ -0,0 +1,23 @@ +/dts-v1/; +/plugin/; + +#include + +/ { + metadata { + title = "Enable CAN1-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO4_C6", "GPIO4_C7"; + description = "Enable CAN1-M1. +On Radxa CM4-RPI-CM4-IO this is TX pin 28 and Rx pin 27."; + }; +}; + +&can1 { + assigned-clocks = <&cru CLK_CAN1>; + assigned-clock-rates = <200000000>; + pinctrl-names = "default"; + pinctrl-0 = <&can1m1_pins>; + status = "okay"; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m3.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m3.dts new file mode 100644 index 00000000..42bd0a7d --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m3.dts @@ -0,0 +1,23 @@ +/dts-v1/; +/plugin/; + +#include + +/ { + metadata { + title = "Enable CAN1-M3"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO3_A2", "GPIO3_A3"; + description = "Enable CAN1-M3. +On Radxa CM4-RPI-CM4-IO this is TX pin 29 and Rx pin 37."; + }; +}; + +&can1 { + assigned-clocks = <&cru CLK_CAN1>; + assigned-clock-rates = <200000000>; + pinctrl-names = "default"; + pinctrl-0 = <&can1m3_pins>; + status = "okay"; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c5-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c5-m1.dts new file mode 100644 index 00000000..8a63ba72 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c5-m1.dts @@ -0,0 +1,19 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable I2C5-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_D5", "GPIO1_D4"; + description = "Enable I2C5-M1. +On Radxa CM4-RPI-CM4-IO this is SDA pin 11 and SCL pin 12. +"; + }; +}; + +&i2c5 { + status = "okay"; + pinctrl-0 = <&i2c5m1_xfer>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c6-m3.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c6-m3.dts new file mode 100644 index 00000000..dcbf4fca --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c6-m3.dts @@ -0,0 +1,19 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable I2C6-M3"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO4_C7", "GPIO4_C6"; + description = "Enable I2C6-M3. +On Radxa CM4-RPI-CM4-IO this is SDA pin 27 and SCL pin 28. +"; + }; +}; + +&i2c6 { + status = "okay"; + pinctrl-0 = <&i2c6m3_xfer>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m1.dts new file mode 100644 index 00000000..8d560a67 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m1.dts @@ -0,0 +1,19 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable I2C8-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_C7", "GPIO1_C6"; + description = "Enable I2C8-M1. +On Radxa CM4-RPI-CM4-IO this is SDA pin 3 and SCL pin 5. +"; + }; +}; + +&i2c8 { + status = "okay"; + pinctrl-0 = <&i2c8m1_xfer>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m2.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m2.dts new file mode 100644 index 00000000..7b20f686 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m2.dts @@ -0,0 +1,19 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable I2C8-M2"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO2_B7", "GPIO2_B6"; + description = "Enable I2C8-M2. +On Radxa CM4-RPI-CM4-IO this is SDA pin 18 and SCL pin 16. +"; + }; +}; + +&i2c8 { + status = "okay"; + pinctrl-0 = <&i2c8m2_xfer>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c9-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c9-m1.dts new file mode 100644 index 00000000..0f29b82d --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c9-m1.dts @@ -0,0 +1,19 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable I2C9-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_B4", "GPIO1_B5"; + description = "Enable I2C9-M1. +On Radxa CM4-RPI-CM4-IO this is SDA pin 23 and SCL pin 19. +"; + }; +}; + +&i2c9 { + status = "okay"; + pinctrl-0 = <&i2c9m1_xfer>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm0-ch0-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm0-ch0-m1.dts new file mode 100644 index 00000000..44b8338b --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm0-ch0-m1.dts @@ -0,0 +1,18 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable PWM0-CH0-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_C0"; + description = "Enable PWM0-CH0-M1. +On Radxa CM4-RPI-CM4-IO this is pin 26."; + }; +}; + +&pwm0_2ch_0 { + status = "okay"; + pinctrl-0 = <&pwm0m1_ch0>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m1.dts new file mode 100644 index 00000000..fbd75511 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m1.dts @@ -0,0 +1,18 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable PWM1-CH0-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_B4"; + description = "Enable PWM1-CH0-M1. +On Radxa CM4-RPI-CM4-IO this is pin 23."; + }; +}; + +&pwm1_6ch_0 { + status = "okay"; + pinctrl-0 = <&pwm1m1_ch0>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m2.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m2.dts new file mode 100644 index 00000000..814bff70 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m2.dts @@ -0,0 +1,18 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable PWM1-CH0-M2"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO2_C0"; + description = "Enable PWM1-CH0-M2. +On Radxa CM4-RPI-CM4-IO this is pin 33."; + }; +}; + +&pwm1_6ch_0 { + status = "okay"; + pinctrl-0 = <&pwm1m2_ch0>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch1-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch1-m1.dts new file mode 100644 index 00000000..bdb7af76 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch1-m1.dts @@ -0,0 +1,18 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable PWM1-CH1-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_B5"; + description = "Enable PWM1-CH1-M1. +On Radxa CM4-RPI-CM4-IO this is pin 19."; + }; +}; + +&pwm1_6ch_1 { + status = "okay"; + pinctrl-0 = <&pwm1m1_ch1>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch2-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch2-m1.dts new file mode 100644 index 00000000..71e6e406 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch2-m1.dts @@ -0,0 +1,18 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable PWM1-CH2-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_C2"; + description = "Enable PWM1-CH2-M1. +On Radxa CM4-RPI-CM4-IO this is pin 32."; + }; +}; + +&pwm1_6ch_2 { + status = "okay"; + pinctrl-0 = <&pwm1m1_ch2>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch3-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch3-m1.dts new file mode 100644 index 00000000..363da6c2 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch3-m1.dts @@ -0,0 +1,18 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable PWM1-CH3-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_D2"; + description = "Enable PWM1-CH3-M1. +On Radxa CM4-RPI-CM4-IO this is pin 36."; + }; +}; + +&pwm1_6ch_3 { + status = "okay"; + pinctrl-0 = <&pwm1m1_ch3>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch4-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch4-m1.dts new file mode 100644 index 00000000..661f67e0 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch4-m1.dts @@ -0,0 +1,18 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable PWM1-CH4-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_D3"; + description = "Enable PWM1-CH4-M1. +On Radxa CM4-RPI-CM4-IO this is pin 38."; + }; +}; + +&pwm1_6ch_4 { + status = "okay"; + pinctrl-0 = <&pwm1m1_ch4>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch2-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch2-m1.dts new file mode 100644 index 00000000..bcb792fa --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch2-m1.dts @@ -0,0 +1,18 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable PWM2-CH2-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO4_C6"; + description = "Enable PWM2-CH2-M1. +On Radxa CM4-RPI-CM4-IO this is pin 28."; + }; +}; + +&pwm2_8ch_2 { + status = "okay"; + pinctrl-0 = <&pwm2m1_ch2>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch3-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch3-m1.dts new file mode 100644 index 00000000..16ffb49d --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch3-m1.dts @@ -0,0 +1,18 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable PWM2-CH3-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO4_C7"; + description = "Enable PWM2-CH3-M1. +On Radxa CM4-RPI-CM4-IO this is pin 27."; + }; +}; + +&pwm2_8ch_3 { + status = "okay"; + pinctrl-0 = <&pwm2m1_ch3>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch7-m2.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch7-m2.dts new file mode 100644 index 00000000..1b010470 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch7-m2.dts @@ -0,0 +1,18 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable PWM2-CH7-M2"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO2_D7"; + description = "Enable PWM2-CH7-M2. +On Radxa CM4-RPI-CM4-IO this is pin 22."; + }; +}; + +&pwm2_8ch_7 { + status = "okay"; + pinctrl-0 = <&pwm2m2_ch7>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs0-spidev.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs0-spidev.dts new file mode 100644 index 00000000..9fb4a664 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs0-spidev.dts @@ -0,0 +1,28 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable spidev on SPI1-M0 over CS0"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_B7", "GPIO1_B4", "GPIO1_B5", "GPIO1_B6"; + description = "Enable spidev on SPI1-M0 over CS0."; + }; +}; + +&spi1 { + status = "okay"; + #address-cells = <1>; + #size-cells = <0>; + pinctrl-names = "default"; + pinctrl-0 = <&spi1m0_csn0 &spi1m0_pins>; + max-freq = <50000000>; + + spidev@0 { + compatible = "rockchip,spidev"; + status = "okay"; + reg = <0>; + spi-max-frequency = <50000000>; + }; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs1-spidev.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs1-spidev.dts new file mode 100644 index 00000000..38917a25 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs1-spidev.dts @@ -0,0 +1,28 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable spidev on SPI1-M0 over CS1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_C0", "GPIO1_B4", "GPIO1_B5", "GPIO1_B6"; + description = "Enable spidev on SPI1-M0 over CS1."; + }; +}; + +&spi1 { + status = "okay"; + #address-cells = <1>; + #size-cells = <0>; + pinctrl-names = "default"; + pinctrl-0 = <&spi1m0_csn1 &spi1m0_pins>; + max-freq = <50000000>; + + spidev@1 { + compatible = "rockchip,spidev"; + status = "okay"; + reg = <1>; + spi-max-frequency = <50000000>; + }; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs0-spidev.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs0-spidev.dts new file mode 100644 index 00000000..4266b5ab --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs0-spidev.dts @@ -0,0 +1,28 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable spidev on SPI2-M1 over CS0"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_C3", "GPIO1_D5", "GPIO1_C4", "GPIO1_C5"; + description = "Enable spidev on SPI2-M1 over CS0."; + }; +}; + +&spi2 { + status = "okay"; + #address-cells = <1>; + #size-cells = <0>; + pinctrl-names = "default"; + pinctrl-0 = <&spi2m1_csn0 &spi2m1_pins>; + max-freq = <50000000>; + + spidev@0 { + compatible = "rockchip,spidev"; + status = "okay"; + reg = <0>; + spi-max-frequency = <50000000>; + }; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs1-spidev.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs1-spidev.dts new file mode 100644 index 00000000..6791a7e4 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs1-spidev.dts @@ -0,0 +1,28 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable spidev on SPI2-M1 over CS1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_C2", "GPIO1_D5", "GPIO1_C4", "GPIO1_C5"; + description = "Enable spidev on SPI2-M1 over CS0."; + }; +}; + +&spi2 { + status = "okay"; + #address-cells = <1>; + #size-cells = <0>; + pinctrl-names = "default"; + pinctrl-0 = <&spi2m1_csn1 &spi2m1_pins>; + max-freq = <50000000>; + + spidev@1 { + compatible = "rockchip,spidev"; + status = "okay"; + reg = <1>; + spi-max-frequency = <50000000>; + }; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart2-m0.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart2-m0.dts new file mode 100644 index 00000000..497850c8 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart2-m0.dts @@ -0,0 +1,19 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable UART2-M0"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_C7", "GPIO1_C6"; + description = "Enable UART2-M0. +On Radxa CM4 RPI CM4 IO this is TX pin 5 & RX pin 3. +"; + }; +}; + +&uart2 { + status = "okay"; + pinctrl-0 = <&uart2m0_xfer>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart3-m2.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart3-m2.dts new file mode 100644 index 00000000..ba9b2933 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart3-m2.dts @@ -0,0 +1,19 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable UART3-M2"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_C0", "GPIO1_C1"; + description = "Enable UART3-M2. +On Radxa CM4 RPI CM4 IO this is TX pin 26 & RX pin 31. +"; + }; +}; + +&uart3 { + status = "okay"; + pinctrl-0 = <&uart3m2_xfer>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart4-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart4-m1.dts new file mode 100644 index 00000000..0136dd03 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart4-m1.dts @@ -0,0 +1,19 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable UART4-M1"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO1_C4", "GPIO1_C5"; + description = "Enable UART4-M1. +On Radxa CM4 RPI CM4 IO this is TX pin 13 & RX pin 15. +"; + }; +}; + +&uart4 { + status = "okay"; + pinctrl-0 = <&uart4m1_xfer>; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart7-m0.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart7-m0.dts new file mode 100644 index 00000000..3ab45602 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart7-m0.dts @@ -0,0 +1,19 @@ +/dts-v1/; +/plugin/; + +/ { + metadata { + title = "Enable UART7-M0"; + compatible = "radxa,cm4-rpi-cm4-io"; + category = "misc"; + exclusive = "GPIO2_B6", "GPIO2_B7"; + description = "Enable UART7-M0. +On Radxa CM4 RPI CM4 IO this is TX pin 16 & RX pin 18. +"; + }; +}; + +&uart7 { + status = "okay"; + pinctrl-0 = <&uart7m0_xfer>; +}; From f96f9c62369b6d4ec53f53e610f79bb842967fa6 Mon Sep 17 00:00:00 2001 From: Stephen Chen Date: Sat, 30 Nov 2024 19:09:51 +0800 Subject: [PATCH 2/5] fix: build CAN dtbo when CONFIG_CPU_RK3576 is defined Signed-off-by: Stephen Chen --- arch/arm64/boot/dts/rockchip/overlays/Makefile | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/arch/arm64/boot/dts/rockchip/overlays/Makefile b/arch/arm64/boot/dts/rockchip/overlays/Makefile index de241e26..71565cac 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/Makefile +++ b/arch/arm64/boot/dts/rockchip/overlays/Makefile @@ -342,8 +342,6 @@ dtb-$(CONFIG_CPU_RK3568) += \ rock-3c-radxa-display-10hd.dtbo dtb-$(CONFIG_CLK_RK3576) += \ - rk3576-can1-m1.dtbo \ - rk3576-can1-m3.dtbo \ rk3576-i2c5-m1.dtbo \ rk3576-i2c6-m3.dtbo \ rk3576-i2c8-m1.dtbo \ @@ -369,7 +367,8 @@ dtb-$(CONFIG_CLK_RK3576) += \ rk3576-uart7-m0.dtbo dtb-$(CONFIG_CPU_RK3576) += \ - + rk3576-can1-m1.dtbo \ + rk3576-can1-m3.dtbo dtb-$(CONFIG_CLK_RK3588) += \ radxa-nx5-io-okdo-camera-5mp-cam0.dtbo \ From 975c14ea5478b052c8c88da4beb580c7057f058c Mon Sep 17 00:00:00 2001 From: Stephen Chen Date: Sat, 30 Nov 2024 19:15:28 +0800 Subject: [PATCH 3/5] fix: add "can1" to "exclusive" for rk3576 can1 dtbo Signed-off-by: Stephen Chen --- arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m1.dts | 2 +- arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m3.dts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m1.dts index 40605b1b..ffdab272 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m1.dts @@ -8,7 +8,7 @@ title = "Enable CAN1-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO4_C6", "GPIO4_C7"; + exclusive = "GPIO4_C6", "GPIO4_C7", "can1"; description = "Enable CAN1-M1. On Radxa CM4-RPI-CM4-IO this is TX pin 28 and Rx pin 27."; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m3.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m3.dts index 42bd0a7d..522365f3 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m3.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-can1-m3.dts @@ -8,7 +8,7 @@ title = "Enable CAN1-M3"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO3_A2", "GPIO3_A3"; + exclusive = "GPIO3_A2", "GPIO3_A3", "can1"; description = "Enable CAN1-M3. On Radxa CM4-RPI-CM4-IO this is TX pin 29 and Rx pin 37."; }; From 11900d11b95d81e65d3e4ffd8cfac0b535cf5078 Mon Sep 17 00:00:00 2001 From: ZHANG Yuntian Date: Sat, 14 Dec 2024 20:35:42 +0800 Subject: [PATCH 4/5] fix: add missing exclusives Signed-off-by: ZHANG Yuntian --- .../dts/rockchip/overlays/rk3568-gpio-ir.dts | 39 +++++++++++++++++++ .../dts/rockchip/overlays/rk3576-i2c5-m1.dts | 2 +- .../dts/rockchip/overlays/rk3576-i2c6-m3.dts | 2 +- .../dts/rockchip/overlays/rk3576-i2c8-m1.dts | 2 +- .../dts/rockchip/overlays/rk3576-i2c8-m2.dts | 2 +- .../dts/rockchip/overlays/rk3576-i2c9-m1.dts | 2 +- .../rockchip/overlays/rk3576-pwm0-ch0-m1.dts | 2 +- .../rockchip/overlays/rk3576-pwm1-ch0-m1.dts | 2 +- .../rockchip/overlays/rk3576-pwm1-ch0-m2.dts | 2 +- .../rockchip/overlays/rk3576-pwm1-ch1-m1.dts | 2 +- .../rockchip/overlays/rk3576-pwm1-ch2-m1.dts | 2 +- .../rockchip/overlays/rk3576-pwm1-ch3-m1.dts | 2 +- .../rockchip/overlays/rk3576-pwm1-ch4-m1.dts | 2 +- .../rockchip/overlays/rk3576-pwm2-ch2-m1.dts | 2 +- .../rockchip/overlays/rk3576-pwm2-ch3-m1.dts | 2 +- .../rockchip/overlays/rk3576-pwm2-ch7-m2.dts | 2 +- .../overlays/rk3576-spi1-m0-cs0-spidev.dts | 2 +- .../overlays/rk3576-spi1-m0-cs1-spidev.dts | 2 +- .../overlays/rk3576-spi2-m1-cs0-spidev.dts | 2 +- .../overlays/rk3576-spi2-m1-cs1-spidev.dts | 2 +- .../dts/rockchip/overlays/rk3576-uart2-m0.dts | 2 +- .../dts/rockchip/overlays/rk3576-uart3-m2.dts | 2 +- .../dts/rockchip/overlays/rk3576-uart4-m1.dts | 2 +- .../dts/rockchip/overlays/rk3576-uart7-m0.dts | 2 +- 24 files changed, 62 insertions(+), 23 deletions(-) create mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3568-gpio-ir.dts diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3568-gpio-ir.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3568-gpio-ir.dts new file mode 100644 index 00000000..39c5b24b --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3568-gpio-ir.dts @@ -0,0 +1,39 @@ +/dts-v1/; +/plugin/; + +#include +#include + +/ { + metadata { + title = "Enable IR receiver on GPIO3_A3"; + compatible = "rockchip,rk3566", "rockchip,rk3568"; + category = "misc"; + exclusive = "GPIO3_A3"; + description = "Enable IR receiver on GPIO3_A3."; + }; +}; + +&{/} { + gpio_ir: gpio-ir { + compatible = "gpio-ir-receiver"; + pinctrl-names = "default"; + pinctrl-0 = <&gpio_ir_pins>; + + // pin number, high or low + gpios = <&gpio1 RK_PB1 GPIO_ACTIVE_HIGH>; + + // parameter for keymap name + linux,rc-map-name = "rc-rc6-mce"; + + status = "okay"; + }; +}; + +&pinctrl { + gpio-ir { + gpio_ir_pins: gpio-ir-pins { + rockchip,pins = <1 RK_PB1 RK_FUNC_GPIO &pcfg_pull_up>; + }; + }; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c5-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c5-m1.dts index 8a63ba72..9505cf87 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c5-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c5-m1.dts @@ -6,7 +6,7 @@ title = "Enable I2C5-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_D5", "GPIO1_D4"; + exclusive = "GPIO1_D5", "GPIO1_D4", "i2c5"; description = "Enable I2C5-M1. On Radxa CM4-RPI-CM4-IO this is SDA pin 11 and SCL pin 12. "; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c6-m3.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c6-m3.dts index dcbf4fca..821c0e1c 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c6-m3.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c6-m3.dts @@ -6,7 +6,7 @@ title = "Enable I2C6-M3"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO4_C7", "GPIO4_C6"; + exclusive = "GPIO4_C7", "GPIO4_C6", "i2c6"; description = "Enable I2C6-M3. On Radxa CM4-RPI-CM4-IO this is SDA pin 27 and SCL pin 28. "; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m1.dts index 8d560a67..75dd7ada 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m1.dts @@ -6,7 +6,7 @@ title = "Enable I2C8-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_C7", "GPIO1_C6"; + exclusive = "GPIO1_C7", "GPIO1_C6", "i2c8"; description = "Enable I2C8-M1. On Radxa CM4-RPI-CM4-IO this is SDA pin 3 and SCL pin 5. "; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m2.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m2.dts index 7b20f686..d76d31eb 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m2.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c8-m2.dts @@ -6,7 +6,7 @@ title = "Enable I2C8-M2"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO2_B7", "GPIO2_B6"; + exclusive = "GPIO2_B7", "GPIO2_B6", "i2c8"; description = "Enable I2C8-M2. On Radxa CM4-RPI-CM4-IO this is SDA pin 18 and SCL pin 16. "; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c9-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c9-m1.dts index 0f29b82d..c0a0055f 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c9-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-i2c9-m1.dts @@ -6,7 +6,7 @@ title = "Enable I2C9-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_B4", "GPIO1_B5"; + exclusive = "GPIO1_B4", "GPIO1_B5", "i2c9"; description = "Enable I2C9-M1. On Radxa CM4-RPI-CM4-IO this is SDA pin 23 and SCL pin 19. "; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm0-ch0-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm0-ch0-m1.dts index 44b8338b..e1db5894 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm0-ch0-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm0-ch0-m1.dts @@ -6,7 +6,7 @@ title = "Enable PWM0-CH0-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_C0"; + exclusive = "GPIO1_C0", "pwm0_2ch_0"; description = "Enable PWM0-CH0-M1. On Radxa CM4-RPI-CM4-IO this is pin 26."; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m1.dts index fbd75511..c556aa2e 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m1.dts @@ -6,7 +6,7 @@ title = "Enable PWM1-CH0-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_B4"; + exclusive = "GPIO1_B4", "pwm1_6ch_0"; description = "Enable PWM1-CH0-M1. On Radxa CM4-RPI-CM4-IO this is pin 23."; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m2.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m2.dts index 814bff70..30e4ce8e 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m2.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch0-m2.dts @@ -6,7 +6,7 @@ title = "Enable PWM1-CH0-M2"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO2_C0"; + exclusive = "GPIO2_C0", "pwm1_6ch_0"; description = "Enable PWM1-CH0-M2. On Radxa CM4-RPI-CM4-IO this is pin 33."; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch1-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch1-m1.dts index bdb7af76..55af76e7 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch1-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch1-m1.dts @@ -6,7 +6,7 @@ title = "Enable PWM1-CH1-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_B5"; + exclusive = "GPIO1_B5", "pwm1_6ch_1"; description = "Enable PWM1-CH1-M1. On Radxa CM4-RPI-CM4-IO this is pin 19."; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch2-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch2-m1.dts index 71e6e406..3df547ad 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch2-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch2-m1.dts @@ -6,7 +6,7 @@ title = "Enable PWM1-CH2-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_C2"; + exclusive = "GPIO1_C2", "pwm1_6ch_1"; description = "Enable PWM1-CH2-M1. On Radxa CM4-RPI-CM4-IO this is pin 32."; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch3-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch3-m1.dts index 363da6c2..aea16afd 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch3-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch3-m1.dts @@ -6,7 +6,7 @@ title = "Enable PWM1-CH3-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_D2"; + exclusive = "GPIO1_D2", "pwm1_6ch_3"; description = "Enable PWM1-CH3-M1. On Radxa CM4-RPI-CM4-IO this is pin 36."; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch4-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch4-m1.dts index 661f67e0..94217adf 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch4-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm1-ch4-m1.dts @@ -6,7 +6,7 @@ title = "Enable PWM1-CH4-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_D3"; + exclusive = "GPIO1_D3", "pwm1_6ch_4"; description = "Enable PWM1-CH4-M1. On Radxa CM4-RPI-CM4-IO this is pin 38."; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch2-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch2-m1.dts index bcb792fa..696cbea1 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch2-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch2-m1.dts @@ -6,7 +6,7 @@ title = "Enable PWM2-CH2-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO4_C6"; + exclusive = "GPIO4_C6", "pwm2_8ch_2"; description = "Enable PWM2-CH2-M1. On Radxa CM4-RPI-CM4-IO this is pin 28."; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch3-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch3-m1.dts index 16ffb49d..ad2e6854 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch3-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch3-m1.dts @@ -6,7 +6,7 @@ title = "Enable PWM2-CH3-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO4_C7"; + exclusive = "GPIO4_C7", "pwm2_8ch_3"; description = "Enable PWM2-CH3-M1. On Radxa CM4-RPI-CM4-IO this is pin 27."; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch7-m2.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch7-m2.dts index 1b010470..1fe8f4f4 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch7-m2.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-pwm2-ch7-m2.dts @@ -6,7 +6,7 @@ title = "Enable PWM2-CH7-M2"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO2_D7"; + exclusive = "GPIO2_D7", "pwm2_8ch_7"; description = "Enable PWM2-CH7-M2. On Radxa CM4-RPI-CM4-IO this is pin 22."; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs0-spidev.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs0-spidev.dts index 9fb4a664..4237350d 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs0-spidev.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs0-spidev.dts @@ -6,7 +6,7 @@ title = "Enable spidev on SPI1-M0 over CS0"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_B7", "GPIO1_B4", "GPIO1_B5", "GPIO1_B6"; + exclusive = "GPIO1_B7", "GPIO1_B4", "GPIO1_B5", "GPIO1_B6", "spi1"; description = "Enable spidev on SPI1-M0 over CS0."; }; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs1-spidev.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs1-spidev.dts index 38917a25..d2ed0b35 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs1-spidev.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi1-m0-cs1-spidev.dts @@ -6,7 +6,7 @@ title = "Enable spidev on SPI1-M0 over CS1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_C0", "GPIO1_B4", "GPIO1_B5", "GPIO1_B6"; + exclusive = "GPIO1_C0", "GPIO1_B4", "GPIO1_B5", "GPIO1_B6", "spi1"; description = "Enable spidev on SPI1-M0 over CS1."; }; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs0-spidev.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs0-spidev.dts index 4266b5ab..2c795307 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs0-spidev.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs0-spidev.dts @@ -6,7 +6,7 @@ title = "Enable spidev on SPI2-M1 over CS0"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_C3", "GPIO1_D5", "GPIO1_C4", "GPIO1_C5"; + exclusive = "GPIO1_C3", "GPIO1_D5", "GPIO1_C4", "GPIO1_C5", "spi2"; description = "Enable spidev on SPI2-M1 over CS0."; }; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs1-spidev.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs1-spidev.dts index 6791a7e4..7af20199 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs1-spidev.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-spi2-m1-cs1-spidev.dts @@ -6,7 +6,7 @@ title = "Enable spidev on SPI2-M1 over CS1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_C2", "GPIO1_D5", "GPIO1_C4", "GPIO1_C5"; + exclusive = "GPIO1_C2", "GPIO1_D5", "GPIO1_C4", "GPIO1_C5", "spi2"; description = "Enable spidev on SPI2-M1 over CS0."; }; }; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart2-m0.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart2-m0.dts index 497850c8..36811811 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart2-m0.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart2-m0.dts @@ -6,7 +6,7 @@ title = "Enable UART2-M0"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_C7", "GPIO1_C6"; + exclusive = "GPIO1_C7", "GPIO1_C6", "uart2"; description = "Enable UART2-M0. On Radxa CM4 RPI CM4 IO this is TX pin 5 & RX pin 3. "; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart3-m2.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart3-m2.dts index ba9b2933..9224f839 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart3-m2.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart3-m2.dts @@ -6,7 +6,7 @@ title = "Enable UART3-M2"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_C0", "GPIO1_C1"; + exclusive = "GPIO1_C0", "GPIO1_C1", "uart3"; description = "Enable UART3-M2. On Radxa CM4 RPI CM4 IO this is TX pin 26 & RX pin 31. "; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart4-m1.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart4-m1.dts index 0136dd03..ce23fe21 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart4-m1.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart4-m1.dts @@ -6,7 +6,7 @@ title = "Enable UART4-M1"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO1_C4", "GPIO1_C5"; + exclusive = "GPIO1_C4", "GPIO1_C5", "uart4"; description = "Enable UART4-M1. On Radxa CM4 RPI CM4 IO this is TX pin 13 & RX pin 15. "; diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart7-m0.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart7-m0.dts index 3ab45602..a47805e1 100644 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart7-m0.dts +++ b/arch/arm64/boot/dts/rockchip/overlays/rk3576-uart7-m0.dts @@ -6,7 +6,7 @@ title = "Enable UART7-M0"; compatible = "radxa,cm4-rpi-cm4-io"; category = "misc"; - exclusive = "GPIO2_B6", "GPIO2_B7"; + exclusive = "GPIO2_B6", "GPIO2_B7", "uart7"; description = "Enable UART7-M0. On Radxa CM4 RPI CM4 IO this is TX pin 16 & RX pin 18. "; From c98fc5abf21890b73e28886c49d3e05d6191e6b3 Mon Sep 17 00:00:00 2001 From: ZHANG Yuntian Date: Sat, 14 Dec 2024 20:43:28 +0800 Subject: [PATCH 5/5] fix: remove mistakenly committed file Signed-off-by: ZHANG Yuntian --- .../dts/rockchip/overlays/rk3568-gpio-ir.dts | 39 ------------------- 1 file changed, 39 deletions(-) delete mode 100644 arch/arm64/boot/dts/rockchip/overlays/rk3568-gpio-ir.dts diff --git a/arch/arm64/boot/dts/rockchip/overlays/rk3568-gpio-ir.dts b/arch/arm64/boot/dts/rockchip/overlays/rk3568-gpio-ir.dts deleted file mode 100644 index 39c5b24b..00000000 --- a/arch/arm64/boot/dts/rockchip/overlays/rk3568-gpio-ir.dts +++ /dev/null @@ -1,39 +0,0 @@ -/dts-v1/; -/plugin/; - -#include -#include - -/ { - metadata { - title = "Enable IR receiver on GPIO3_A3"; - compatible = "rockchip,rk3566", "rockchip,rk3568"; - category = "misc"; - exclusive = "GPIO3_A3"; - description = "Enable IR receiver on GPIO3_A3."; - }; -}; - -&{/} { - gpio_ir: gpio-ir { - compatible = "gpio-ir-receiver"; - pinctrl-names = "default"; - pinctrl-0 = <&gpio_ir_pins>; - - // pin number, high or low - gpios = <&gpio1 RK_PB1 GPIO_ACTIVE_HIGH>; - - // parameter for keymap name - linux,rc-map-name = "rc-rc6-mce"; - - status = "okay"; - }; -}; - -&pinctrl { - gpio-ir { - gpio_ir_pins: gpio-ir-pins { - rockchip,pins = <1 RK_PB1 RK_FUNC_GPIO &pcfg_pull_up>; - }; - }; -};