Skip to contentSkip to conversation

ARM: dts: rockchip: Add Luckfox Lyra boards

PATCH Applied Jonas Karlman 2 participants 8 messages Nov 25 – Nov 29

Subsystems (5)
lore
Share & tools
lore
#0 lore raw

v3 cover ARM: dts: rockchip: Add Luckfox Lyra boards

This series adds initial devicetree for Rockchip RK3506 SoC and initial support for Luckfox Lyra board family [1].

The Luckfox Lyra board family use different RK3506 SoC variants, i.e. Lyra and Lyra Plus both use RK3506G2 and Lyra Ultra and Lyra Zero W both use the RK3506B variant.

The RK3506G2 SoC variant has 128 MiB integrated DDR3 memory and the RK3506B SoC variant supports external DDR2/DDR3 memory.

The pinctrl driver for RK3506 will not work as-is using the SoC DT from this series. The already merged driver depends on a rockchip,ioc1 phandle prop that never was described in dt-bindings. The SoC DT in this series instead uses rockchip,grf in GPIO controller node to reference correct IOC for GPIO0 and GPIO1. A patch to fix the pinctrl driver can be found at [2].

The branch at [3] also contains follow-up patches that e.g. fixes pinctrl driver and adds USB support.

Mainline U-Boot support can be tested using a branch at [4], it contains board support using same devicetree files extended with USB support.

Changes in v3:
- Squash board compatible patches
- Add spi_nand label to flash@0 node
- Drop unnecessary /omit-if-no-ref/ on led1
- Collect a-b and r-b tags
Link to v2: https://patch.msgid.link/[email protected]/

Changes in v2:
- Add default pinctrl to fspi node
- Add display_subsystem, vop, dsi and dsi_dphy nodes
- Add osc_clk_out and ref_clk0_out to pinctrl
Link to v1: https://patch.msgid.link/[email protected]/

[1] https://wiki.luckfox.com/Luckfox-Lyra
[2] https://patch.msgid.link/[email protected]/
[3] https://github.com/Kwiboo/linux-rockchip/commits/next-20261116-rk3506
[4] https://git.u-boot-project.org/u-boot/contributors/kwiboo/u-boot/-/commits/rk3506

Jonas Karlman (6):
dt-bindings: soc: rockchip: grf: Add RK3506 compatibles
ARM: dts: rockchip: Add support for RK3506
dt-bindings: arm: rockchip: Add Luckfox Lyra boards
ARM: dts: rockchip: Add Luckfox Lyra and Lyra Plus boards
ARM: dts: rockchip: Add Luckfox Lyra Ultra board
ARM: dts: rockchip: Add Luckfox Lyra Zero W board

 .../devicetree/bindings/arm/rockchip.yaml     |   9 +
 .../devicetree/bindings/soc/rockchip/grf.yaml |   6 +
 arch/arm/boot/dts/rockchip/Makefile           |   6 +-
 .../dts/rockchip/rk3506-luckfox-lyra-plus.dts |  31 +
 .../boot/dts/rockchip/rk3506-luckfox-lyra.dts |   9 +
 .../dts/rockchip/rk3506-luckfox-lyra.dtsi     | 123 ++++
 .../arm/boot/dts/rockchip/rk3506-pinctrl.dtsi | 594 +++++++++++++++++
 arch/arm/boot/dts/rockchip/rk3506.dtsi        | 614 ++++++++++++++++++
 .../rockchip/rk3506b-luckfox-lyra-ultra.dts   |  31 +
 .../rockchip/rk3506b-luckfox-lyra-zero-w.dts  |  23 +
 .../dts/rockchip/rk3506b-luckfox-lyra.dtsi    |  99 +++
 11 files changed, 1544 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506-luckfox-lyra-plus.dts
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506-luckfox-lyra.dts
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506-luckfox-lyra.dtsi
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506-pinctrl.dtsi
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506.dtsi
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506b-luckfox-lyra-ultra.dts
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506b-luckfox-lyra-zero-w.dts
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506b-luckfox-lyra.dtsi

---
Based-on: <[email protected]>

Signature · 1 line
2.56.1
#1 lore raw

PATCH v3 1/6 dt-bindings: soc: rockchip: grf: Add RK3506 compatibles

Add the GRF and IOC compatible strings for the Rockchip RK3506 SoC.

Table 1-1 RK3506 Address Mapping in TRM for RK3506 contains following related entries:

Module Address Size
GRF 0xFF288000 16KB
GPIO2/3/4_IOC 0xFF4D8000 32KB
GPIO1_IOC 0xFF660000 64KB
GRF_CORE 0xFF840000 16KB
GRF_PMU/RMIO 0xFF910000 16KB
GPIO0_IOC 0xFF950000 64KB

---
Changes in v3:
- Collect a-b tag
Changes in v2:
- No change

---
 Documentation/devicetree/bindings/soc/rockchip/grf.yaml | 6 ++++++
 1 file changed, 6 insertions(+)
Documentation/devicetree/bindings/soc/rockchip/grf.yaml +6 -0
index e94c83d7c138..3c1c3dc1b84d 100644
@@ -15,6 +15,9 @@ properties:
       - items:
           - enum:
               - rockchip,rk3288-sgrf
+              - rockchip,rk3506-ioc0
+              - rockchip,rk3506-ioc1
+              - rockchip,rk3506-ioc234
               - rockchip,rk3528-ioc-grf
               - rockchip,rk3528-pipe-phy-grf
               - rockchip,rk3528-vo-grf
@@ -93,6 +96,9 @@ properties:
               - rockchip,rk3368-pmugrf
               - rockchip,rk3399-grf
               - rockchip,rk3399-pmugrf
+              - rockchip,rk3506-core-grf
+              - rockchip,rk3506-grf
+              - rockchip,rk3506-pmu-grf
               - rockchip,rk3562-pmu-grf
               - rockchip,rk3568-grf
               - rockchip,rk3568-pmugrf
Signature · 1 line
2.56.1
#2 lore raw

PATCH v3 2/6 ARM: dts: rockchip: Add support for RK3506

In reply to Jonas Karlman

Add the initial devicetree for Rockchip RK3506 SoC.

---
Changes in v3:
- Collect r-b tag
Changes in v2:
- Add default pinctrl to fspi node
- Add display_subsystem, vop, dsi and dsi_dphy nodes
- Add osc_clk_out and ref_clk0_out to pinctrl

---
 .../arm/boot/dts/rockchip/rk3506-pinctrl.dtsi | 594 +++++++++++++++++
 arch/arm/boot/dts/rockchip/rk3506.dtsi        | 614 ++++++++++++++++++
 2 files changed, 1208 insertions(+)
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506-pinctrl.dtsi
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506.dtsi
arch/arm/boot/dts/rockchip/rk3506-pinctrl.dtsi new file +594 -0
new file mode 100644
index 000000000000..72cebe2428f8
@@ -0,0 +1,594 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+
+#include <dt-bindings/pinctrl/rockchip.h>
+#include <arm64/rockchip/rockchip-pinconf.dtsi>
+
+&pinctrl {
+	aupll-clk {
+		/omit-if-no-ref/
+		aupll_clk_in: aupll-clk-in {
+			rockchip,pins =
+				/* aupll_clk_in */
+				<0 RK_PC4 2 &pcfg_pull_none>;
+		};
+	};
+
+	cpu {
+		/omit-if-no-ref/
+		cpu_avs: cpu-avs {
+			rockchip,pins =
+				/* cpu_avs */
+				<0 RK_PC5 1 &pcfg_pull_none>;
+		};
+	};
+
+	eth-clk0-25m {
+		/omit-if-no-ref/
+		eth_clk0_25m_out: eth-clk0-25m-out {
+			rockchip,pins =
+				/* eth_clk0_25m_out */
+				<0 RK_PC4 1 &pcfg_pull_none>;
+		};
+	};
+
+	eth-clk1-25m {
+		/omit-if-no-ref/
+		eth_clk1_25m_out: eth-clk1-25m-out {
+			rockchip,pins =
+				/* eth_clk1_25m_out */
+				<0 RK_PC3 1 &pcfg_pull_none>;
+		};
+	};
+
+	eth-rmii0 {
+		/omit-if-no-ref/
+		eth_rmii0_clk: eth-rmii0-clk {
+			rockchip,pins =
+				/* eth_rmii0_clk */
+				<2 RK_PB2 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		eth_rmii0_miim: eth-rmii0-miim {
+			rockchip,pins =
+				/* eth_rmii0_mdc */
+				<2 RK_PB6 1 &pcfg_pull_none>,
+				/* eth_rmii0_mdio */
+				<2 RK_PB7 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		eth_rmii0_rx_bus2: eth-rmii0-rx-bus2 {
+			rockchip,pins =
+				/* eth_rmii0_rxd0 */
+				<2 RK_PB0 1 &pcfg_pull_none>,
+				/* eth_rmii0_rxd1 */
+				<2 RK_PB1 1 &pcfg_pull_none>,
+				/* eth_rmii0_rxdvcrs */
+				<2 RK_PC0 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		eth_rmii0_tx_bus2: eth-rmii0-tx-bus2 {
+			rockchip,pins =
+				/* eth_rmii0_txd0 */
+				<2 RK_PB3 1 &pcfg_pull_none>,
+				/* eth_rmii0_txd1 */
+				<2 RK_PB4 1 &pcfg_pull_none>,
+				/* eth_rmii0_txen */
+				<2 RK_PB5 1 &pcfg_pull_none>;
+		};
+	};
+
+	eth-rmii1 {
+		/omit-if-no-ref/
+		eth_rmii1_clk: eth-rmii1-clk {
+			rockchip,pins =
+				/* eth_rmii1_clk */
+				<3 RK_PB0 2 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		eth_rmii1_miim: eth-rmii1-miim {
+			rockchip,pins =
+				/* eth_rmii1_mdc */
+				<3 RK_PB4 2 &pcfg_pull_none>,
+				/* eth_rmii1_mdio */
+				<3 RK_PB5 2 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		eth_rmii1_rx_bus2: eth-rmii1-rx-bus2 {
+			rockchip,pins =
+				/* eth_rmii1_rxd0 */
+				<3 RK_PA6 2 &pcfg_pull_none>,
+				/* eth_rmii1_rxd1 */
+				<3 RK_PA7 2 &pcfg_pull_none>,
+				/* eth_rmii1_rxdvcrs */
+				<3 RK_PB6 2 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		eth_rmii1_tx_bus2: eth-rmii1-tx-bus2 {
+			rockchip,pins =
+				/* eth_rmii1_txd0 */
+				<3 RK_PB1 2 &pcfg_pull_none>,
+				/* eth_rmii1_txd1 */
+				<3 RK_PB2 2 &pcfg_pull_none>,
+				/* eth_rmii1_txen */
+				<3 RK_PB3 2 &pcfg_pull_none>;
+		};
+	};
+
+	fspi {
+		/omit-if-no-ref/
+		fspi_bus4: fspi-bus4 {
+			rockchip,pins =
+				/* fspi_d0 */
+				<2 RK_PA2 1 &pcfg_pull_none>,
+				/* fspi_d1 */
+				<2 RK_PA3 1 &pcfg_pull_none>,
+				/* fspi_d2 */
+				<2 RK_PA4 1 &pcfg_pull_none>,
+				/* fspi_d3 */
+				<2 RK_PA5 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		fspi_clk: fspi-clk {
+			rockchip,pins =
+				/* fspi_clk */
+				<2 RK_PA1 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		fspi_csn: fspi-csn {
+			rockchip,pins =
+				/* fspi_csn */
+				<2 RK_PA0 1 &pcfg_pull_none>;
+		};
+	};
+
+	jtag {
+		/omit-if-no-ref/
+		jtagm0: jtagm0 {
+			rockchip,pins =
+				/* jtag_tck_m0 */
+				<3 RK_PA4 2 &pcfg_pull_none>,
+				/* jtag_tms_m0 */
+				<3 RK_PA5 2 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		jtagm1: jtagm1 {
+			rockchip,pins =
+				/* jtag_tck_m1 */
+				<0 RK_PC6 2 &pcfg_pull_none>,
+				/* jtag_tms_m1 */
+				<0 RK_PC7 2 &pcfg_pull_none>;
+		};
+	};
+
+	osc-clk {
+		/omit-if-no-ref/
+		osc_clk_out: osc-clk-out {
+			rockchip,pins =
+				/* osc_clk_out */
+				<0 RK_PD0 1 &pcfg_pull_none>;
+		};
+	};
+
+	ref-clk0 {
+		/omit-if-no-ref/
+		ref_clk0_out: ref-clk0-out {
+			rockchip,pins =
+				/* ref_clk0_out */
+				<0 RK_PD0 2 &pcfg_pull_none>;
+		};
+	};
+
+	ref-clk1 {
+		/omit-if-no-ref/
+		ref_clk1_out: ref-clk1-out {
+			rockchip,pins =
+				/* ref_clk1_out */
+				<0 RK_PC2 1 &pcfg_pull_none>;
+		};
+	};
+
+	sai0 {
+		/omit-if-no-ref/
+		sai0_lrck: sai0-lrck {
+			rockchip,pins =
+				/* sai0_lrck */
+				<0 RK_PA0 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai0_mclk: sai0-mclk {
+			rockchip,pins =
+				/* sai0_mclk */
+				<0 RK_PA2 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai0_sclk: sai0-sclk {
+			rockchip,pins =
+				/* sai0_sclk */
+				<0 RK_PA1 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai0_sdi0: sai0-sdi0 {
+			rockchip,pins =
+				/* sai0_sdi0 */
+				<0 RK_PA4 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai0_sdi1: sai0-sdi1 {
+			rockchip,pins =
+				/* sai0_sdi1 */
+				<0 RK_PA5 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai0_sdi2: sai0-sdi2 {
+			rockchip,pins =
+				/* sai0_sdi2 */
+				<0 RK_PA6 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai0_sdi3: sai0-sdi3 {
+			rockchip,pins =
+				/* sai0_sdi3 */
+				<0 RK_PA7 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai0_sdo: sai0-sdo {
+			rockchip,pins =
+				/* sai0_sdo */
+				<0 RK_PA3 1 &pcfg_pull_none>;
+		};
+	};
+
+	sai1 {
+		/omit-if-no-ref/
+		sai1_lrck: sai1-lrck {
+			rockchip,pins =
+				/* sai1_lrck */
+				<0 RK_PB2 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai1_mclk: sai1-mclk {
+			rockchip,pins =
+				/* sai1_mclk */
+				<0 RK_PB0 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai1_sclk: sai1-sclk {
+			rockchip,pins =
+				/* sai1_sclk */
+				<0 RK_PB1 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai1_sdi: sai1-sdi {
+			rockchip,pins =
+				/* sai1_sdi */
+				<0 RK_PB3 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai1_sdo0: sai1-sdo0 {
+			rockchip,pins =
+				/* sai1_sdo0 */
+				<0 RK_PB4 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai1_sdo1: sai1-sdo1 {
+			rockchip,pins =
+				/* sai1_sdo1 */
+				<0 RK_PB5 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai1_sdo2: sai1-sdo2 {
+			rockchip,pins =
+				/* sai1_sdo2 */
+				<0 RK_PB6 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai1_sdo3: sai1-sdo3 {
+			rockchip,pins =
+				/* sai1_sdo3 */
+				<0 RK_PB7 1 &pcfg_pull_none>;
+		};
+	};
+
+	sai2 {
+		/omit-if-no-ref/
+		sai2m0_lrck: sai2m0-lrck {
+			rockchip,pins =
+				/* sai2_lrck_m0 */
+				<3 RK_PB1 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai2m0_mclk: sai2m0-mclk {
+			rockchip,pins =
+				/* sai2_mclk_m0 */
+				<3 RK_PB6 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai2m0_sclk: sai2m0-sclk {
+			rockchip,pins =
+				/* sai2_sclk_m0 */
+				<3 RK_PA7 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai2m0_sdi: sai2m0-sdi {
+			rockchip,pins =
+				/* sai2m0_sdi */
+				<3 RK_PA6 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai2m0_sdo: sai2m0-sdo {
+			rockchip,pins =
+				/* sai2m0_sdo */
+				<3 RK_PB0 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai2m1_lrck: sai2m1-lrck {
+			rockchip,pins =
+				/* sai2_lrck_m1 */
+				<1 RK_PB3 6 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai2m1_mclk: sai2m1-mclk {
+			rockchip,pins =
+				/* sai2_mclk_m1 */
+				<1 RK_PC1 6 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai2m1_sclk: sai2m1-sclk {
+			rockchip,pins =
+				/* sai2_sclk_m1 */
+				<1 RK_PB2 6 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai2m1_sdi: sai2m1-sdi {
+			rockchip,pins =
+				/* sai2m1_sdi */
+				<1 RK_PC2 6 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai2m1_sdo: sai2m1-sdo {
+			rockchip,pins =
+				/* sai2m1_sdo */
+				<1 RK_PC3 6 &pcfg_pull_none>;
+		};
+	};
+
+	sai3 {
+		/omit-if-no-ref/
+		sai3_lrck: sai3-lrck {
+			rockchip,pins =
+				/* sai3_lrck */
+				<2 RK_PB5 3 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai3_mclk: sai3-mclk {
+			rockchip,pins =
+				/* sai3_mclk */
+				<2 RK_PC0 3 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai3_sclk: sai3-sclk {
+			rockchip,pins =
+				/* sai3_sclk */
+				<2 RK_PB4 3 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai3_sdi: sai3-sdi {
+			rockchip,pins =
+				/* sai3_sdi */
+				<2 RK_PB6 3 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sai3_sdo: sai3-sdo {
+			rockchip,pins =
+				/* sai3_sdo */
+				<2 RK_PB7 3 &pcfg_pull_none>;
+		};
+	};
+
+	sdmmc {
+		/omit-if-no-ref/
+		sdmmc_bus4: sdmmc-bus4 {
+			rockchip,pins =
+				/* sdmmc_d0 */
+				<3 RK_PA2 1 &pcfg_pull_up>,
+				/* sdmmc_d1 */
+				<3 RK_PA3 1 &pcfg_pull_up>,
+				/* sdmmc_d2 */
+				<3 RK_PA4 1 &pcfg_pull_up>,
+				/* sdmmc_d3 */
+				<3 RK_PA5 1 &pcfg_pull_up>;
+		};
+
+		/omit-if-no-ref/
+		sdmmc_clk: sdmmc-clk {
+			rockchip,pins =
+				/* sdmmc_clk */
+				<3 RK_PA0 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		sdmmc_cmd: sdmmc-cmd {
+			rockchip,pins =
+				/* sdmmc_cmd */
+				<3 RK_PA1 1 &pcfg_pull_up>;
+		};
+	};
+
+	spi0 {
+		/omit-if-no-ref/
+		spi0_clk: spi0-clk {
+			rockchip,pins =
+				/* spi0_clk */
+				<0 RK_PC0 2 &pcfg_pull_none_drv_level_3>,
+				/* spi0_miso */
+				<0 RK_PC2 2 &pcfg_pull_none_drv_level_3>,
+				/* spi0_mosi */
+				<0 RK_PC1 2 &pcfg_pull_none_drv_level_3>;
+		};
+
+		/omit-if-no-ref/
+		spi0_csn0: spi0-csn0 {
+			rockchip,pins =
+				/* spi0_csn0 */
+				<0 RK_PC3 2 &pcfg_pull_none_drv_level_3>;
+		};
+
+		/omit-if-no-ref/
+		spi0_csn1: spi0-csn1 {
+			rockchip,pins =
+				/* spi0_csn1 */
+				<0 RK_PB7 2 &pcfg_pull_none_drv_level_3>;
+		};
+	};
+
+	spi1 {
+		/omit-if-no-ref/
+		spi1_clk: spi1-clk {
+			rockchip,pins =
+				/* spi1_clk */
+				<0 RK_PB0 2 &pcfg_pull_none_drv_level_3>,
+				/* spi1_miso */
+				<0 RK_PB2 2 &pcfg_pull_none_drv_level_3>,
+				/* spi1_mosi */
+				<0 RK_PB1 2 &pcfg_pull_none_drv_level_3>;
+		};
+
+		/omit-if-no-ref/
+		spi1_csn0: spi1-csn0 {
+			rockchip,pins =
+				/* spi1_csn0 */
+				<0 RK_PB6 2 &pcfg_pull_none_drv_level_3>;
+		};
+
+		/omit-if-no-ref/
+		spi1_csn1: spi1-csn1 {
+			rockchip,pins =
+				/* spi1_csn1 */
+				<0 RK_PA7 2 &pcfg_pull_none_drv_level_3>;
+		};
+	};
+
+	spi2 {
+		/omit-if-no-ref/
+		spi2_clk: spi2-clk {
+			rockchip,pins =
+				/* spi2_clk */
+				<2 RK_PB0 2 &pcfg_pull_none>,
+				/* spi2_miso */
+				<2 RK_PB3 2 &pcfg_pull_none>,
+				/* spi2_mosi */
+				<2 RK_PB2 2 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		spi2_csn: spi2-csn {
+			rockchip,pins =
+				/* spi2_csn */
+				<2 RK_PB1 2 &pcfg_pull_none>;
+		};
+	};
+
+	test-clk {
+		/omit-if-no-ref/
+		test_clk_out: test-clk-out {
+			rockchip,pins =
+				/* test_clk_out */
+				<3 RK_PA3 2 &pcfg_pull_none>;
+		};
+	};
+
+	uart0 {
+		/omit-if-no-ref/
+		uart0_xfer: uart0-xfer {
+			rockchip,pins =
+				/* uart0_rx */
+				<0 RK_PC7 1 &pcfg_pull_up>,
+				/* uart0_tx */
+				<0 RK_PC6 1 &pcfg_pull_up>;
+		};
+	};
+
+	uart5 {
+		/omit-if-no-ref/
+		uart5m0_ctsn: uart5m0-ctsn {
+			rockchip,pins =
+				/* uart5m0_ctsn */
+				<3 RK_PB2 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		uart5m0_rtsn: uart5m0-rtsn {
+			rockchip,pins =
+				/* uart5m0_rtsn */
+				<3 RK_PB5 1 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		uart5m0_xfer: uart5m0-xfer {
+			rockchip,pins =
+				/* uart5_rx_m0 */
+				<3 RK_PB3 1 &pcfg_pull_up>,
+				/* uart5_tx_m0 */
+				<3 RK_PB4 1 &pcfg_pull_up>;
+		};
+
+		/omit-if-no-ref/
+		uart5m1_ctsn: uart5m1-ctsn {
+			rockchip,pins =
+				/* uart5m1_ctsn */
+				<1 RK_PB1 6 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		uart5m1_rtsn: uart5m1-rtsn {
+			rockchip,pins =
+				/* uart5m1_rtsn */
+				<1 RK_PD1 6 &pcfg_pull_none>;
+		};
+
+		/omit-if-no-ref/
+		uart5m1_xfer: uart5m1-xfer {
+			rockchip,pins =
+				/* uart5_rx_m1 */
+				<1 RK_PD3 6 &pcfg_pull_up>,
+				/* uart5_tx_m1 */
+				<1 RK_PD2 6 &pcfg_pull_up>;
+		};
+	};
+};
arch/arm/boot/dts/rockchip/rk3506.dtsi new file +614 -0

614 lines not on this page · raw message

Signature · 1 line
2.56.1
#3 lore raw

PATCH v3 3/6 dt-bindings: arm: rockchip: Add Luckfox Lyra boards

In reply to Jonas Karlman

Add board compatibles for the Luckfox Lyra, Lyra Plus, Lyra Ultra and Lyra Zero W boards.

The Lyra and Lyra Plus use the Rockchip RK3506G2 SoC variant with 128 MiB integrated DDR3 memory. The Lyra Ultra and Lyra Zero W use the RK3506B SoC variant with 512 MiB external DDR3 memory.

---
Changes in v3:
- Update commit message
- Squash patches
- Collect a-b tag
Changes in v2:
- No change

---
 Documentation/devicetree/bindings/arm/rockchip.yaml | 9 +++++++++
 1 file changed, 9 insertions(+)
Documentation/devicetree/bindings/arm/rockchip.yaml +9 -0
index a5eec2ecf23c..49c61ee985e7 100644
@@ -860,6 +860,15 @@ properties:
           - const: luckfox,core3576
           - const: rockchip,rk3576
 
+      - description: Luckfox Lyra boards
+        items:
+          - enum:
+              - luckfox,lyra
+              - luckfox,lyra-plus
+              - luckfox,lyra-ultra
+              - luckfox,lyra-zero-w
+          - const: rockchip,rk3506
+
       - description: Lunzn FastRhino R66S / R68S
         items:
           - enum:
Signature · 1 line
2.56.1
#4 lore raw

PATCH v3 4/6 ARM: dts: rockchip: Add Luckfox Lyra and Lyra Plus boards

In reply to Jonas Karlman

Luckfox Lyra and Lyra Plus is powered by the Rockchip RK3506G2 SoC, which integrates three Cortex-A7 cores, one Cortex-M0 core, and 128 MB of DDR3 memory.

---
Changes in v3:
- Add spi_nand label to flash@0 node
- Drop unnecessary /omit-if-no-ref/ on led1
Changes in v2:
- No change

---
 arch/arm/boot/dts/rockchip/Makefile           |   4 +-
 .../dts/rockchip/rk3506-luckfox-lyra-plus.dts |  31 +++++
 .../boot/dts/rockchip/rk3506-luckfox-lyra.dts |   9 ++
 .../dts/rockchip/rk3506-luckfox-lyra.dtsi     | 123 ++++++++++++++++++
 4 files changed, 166 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506-luckfox-lyra-plus.dts
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506-luckfox-lyra.dts
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506-luckfox-lyra.dtsi
arch/arm/boot/dts/rockchip/Makefile +3 -1
index e9f9e0ac3bfd..df620116bb2d 100644
@@ -45,4 +45,6 @@ dtb-$(CONFIG_ARCH_ROCKCHIP) += \
 	rk3288-veyron-pinky.dtb \
 	rk3288-veyron-speedy.dtb \
 	rk3288-veyron-tiger.dtb \
-	rk3288-vyasa.dtb
+	rk3288-vyasa.dtb \
+	rk3506-luckfox-lyra-plus.dtb \
+	rk3506-luckfox-lyra.dtb
arch/arm/boot/dts/rockchip/rk3506-luckfox-lyra-plus.dts new file +31 -0
new file mode 100644
index 000000000000..c8991f4179bd
@@ -0,0 +1,31 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+
+/dts-v1/;
+#include "rk3506-luckfox-lyra.dtsi"
+
+/ {
+	model = "Luckfox Lyra Plus";
+	compatible = "luckfox,lyra-plus", "rockchip,rk3506";
+
+	aliases {
+		ethernet0 = &gmac1;
+	};
+};
+
+&gmac1 {
+	assigned-clocks = <&cru CLK_MAC1>;
+	assigned-clock-rates = <50000000>;
+	phy-handle = <&rmii_phy1>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&eth_rmii1_miim>, <&eth_rmii1_tx_bus2>,
+		    <&eth_rmii1_rx_bus2>, <&eth_rmii1_clk>;
+	clock_in_out = "output";
+	status = "okay";
+};
+
+&mdio1 {
+	rmii_phy1: ethernet-phy@1 {
+		compatible = "ethernet-phy-ieee802.3-c22";
+		reg = <1>;
+	};
+};
arch/arm/boot/dts/rockchip/rk3506-luckfox-lyra.dts new file +9 -0
new file mode 100644
index 000000000000..b7f11c7c510f
@@ -0,0 +1,9 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+
+/dts-v1/;
+#include "rk3506-luckfox-lyra.dtsi"
+
+/ {
+	model = "Luckfox Lyra";
+	compatible = "luckfox,lyra", "rockchip,rk3506";
+};
arch/arm/boot/dts/rockchip/rk3506-luckfox-lyra.dtsi new file +123 -0

123 lines not on this page · raw message

Signature · 1 line
2.56.1
#5 lore raw

PATCH v3 5/6 ARM: dts: rockchip: Add Luckfox Lyra Ultra board

In reply to Jonas Karlman

Luckfox Lyra Ultra is powered by the Rockchip RK3506B SoC, which integrates three Cortex-A7 cores and one Cortex-M0 core. It includes 512 MB of DDR3 memory, 8 GB of eMMC storage, MIPI DSI, Ethernet, and IO expansion interfaces.

---
Changes in v3:
- Drop unnecessary /omit-if-no-ref/ on led1
Changes in v2:
- No change

---
 arch/arm/boot/dts/rockchip/Makefile           |  3 +-
 .../rockchip/rk3506b-luckfox-lyra-ultra.dts   | 31 ++++++
 .../dts/rockchip/rk3506b-luckfox-lyra.dtsi    | 99 +++++++++++++++++++
 3 files changed, 132 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506b-luckfox-lyra-ultra.dts
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506b-luckfox-lyra.dtsi
arch/arm/boot/dts/rockchip/Makefile +2 -1
index df620116bb2d..9a699bb8fc5a 100644
@@ -47,4 +47,5 @@ dtb-$(CONFIG_ARCH_ROCKCHIP) += \
 	rk3288-veyron-tiger.dtb \
 	rk3288-vyasa.dtb \
 	rk3506-luckfox-lyra-plus.dtb \
-	rk3506-luckfox-lyra.dtb
+	rk3506-luckfox-lyra.dtb \
+	rk3506b-luckfox-lyra-ultra.dtb
arch/arm/boot/dts/rockchip/rk3506b-luckfox-lyra-ultra.dts new file +31 -0
new file mode 100644
index 000000000000..5a3eb35eb70e
@@ -0,0 +1,31 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+
+/dts-v1/;
+#include "rk3506b-luckfox-lyra.dtsi"
+
+/ {
+	model = "Luckfox Lyra Ultra";
+	compatible = "luckfox,lyra-ultra", "rockchip,rk3506";
+
+	aliases {
+		ethernet0 = &gmac1;
+	};
+};
+
+&gmac1 {
+	assigned-clocks = <&cru CLK_MAC1>;
+	assigned-clock-rates = <50000000>;
+	phy-handle = <&rmii_phy1>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&eth_rmii1_miim>, <&eth_rmii1_tx_bus2>,
+		    <&eth_rmii1_rx_bus2>, <&eth_rmii1_clk>;
+	clock_in_out = "output";
+	status = "okay";
+};
+
+&mdio1 {
+	rmii_phy1: ethernet-phy@1 {
+		compatible = "ethernet-phy-ieee802.3-c22";
+		reg = <1>;
+	};
+};
arch/arm/boot/dts/rockchip/rk3506b-luckfox-lyra.dtsi new file +99 -0

99 lines not on this page · raw message

Signature · 1 line
2.56.1
#6 lore raw

PATCH v3 6/6 ARM: dts: rockchip: Add Luckfox Lyra Zero W board

In reply to Jonas Karlman

Luckfox Lyra Zero W is a compact wireless development board powered by the Rockchip RK3506B SoC. It includes 512 MB of DDR3 memory, 256 MB of SPI NAND flash, 2.4 GHz Wi-Fi 6, Bluetooth 5.2, and BLE connectivity. MIPI DSI, USB OTG, USB Host, and RM_IO interfaces are available for peripheral expansion.

---
Changes in v3:
- Add spi_nand label to flash@0 node
Changes in v2:
- No change

---
 arch/arm/boot/dts/rockchip/Makefile           |  3 ++-
 .../rockchip/rk3506b-luckfox-lyra-zero-w.dts  | 23 +++++++++++++++++++
 2 files changed, 25 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/boot/dts/rockchip/rk3506b-luckfox-lyra-zero-w.dts
arch/arm/boot/dts/rockchip/Makefile +2 -1
index 9a699bb8fc5a..faebeb20f467 100644
@@ -48,4 +48,5 @@ dtb-$(CONFIG_ARCH_ROCKCHIP) += \
 	rk3288-vyasa.dtb \
 	rk3506-luckfox-lyra-plus.dtb \
 	rk3506-luckfox-lyra.dtb \
-	rk3506b-luckfox-lyra-ultra.dtb
+	rk3506b-luckfox-lyra-ultra.dtb \
+	rk3506b-luckfox-lyra-zero-w.dtb
arch/arm/boot/dts/rockchip/rk3506b-luckfox-lyra-zero-w.dts new file +23 -0
new file mode 100644
index 000000000000..1ca6a25382f5
@@ -0,0 +1,23 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+
+/dts-v1/;
+#include "rk3506b-luckfox-lyra.dtsi"
+
+/ {
+	model = "Luckfox Lyra Zero W";
+	compatible = "luckfox,lyra-zero-w", "rockchip,rk3506";
+};
+
+&fspi {
+	status = "okay";
+
+	spi_nand: flash@0 {
+		compatible = "spi-nand";
+		reg = <0>;
+		bootph-pre-ram;
+		bootph-some-ram;
+		spi-max-frequency = <80000000>;
+		spi-rx-bus-width = <4>;
+		spi-tx-bus-width = <1>;
+	};
+};
Signature · 1 line
2.56.1
maintainer Applied
#7 lore raw
In reply to Jonas Karlman
Quoted 8 lines · Jonas Karlman

This series adds initial devicetree for Rockchip RK3506 SoC and initial support for Luckfox Lyra board family [1].

The Luckfox Lyra board family use different RK3506 SoC variants, i.e. Lyra and Lyra Plus both use RK3506G2 and Lyra Ultra and Lyra Zero W both use the RK3506B variant.

[...]

Applied, thanks!

[1/6] dt-bindings: soc: rockchip: grf: Add RK3506 compatibles

      commit: f752ed13792eaa2efa42de3d7c4c1643ddffb877
[2/6] ARM: dts: rockchip: Add support for RK3506
      commit: cded8e47d77ac1b19a5c8ba1b4f4fc99245505e2
[3/6] dt-bindings: arm: rockchip: Add Luckfox Lyra boards
      commit: 9ae65871cca64bdca80d19a09334925ae1ea65f6
[4/6] ARM: dts: rockchip: Add Luckfox Lyra and Lyra Plus boards
      commit: 1ab9d2d5f144d221e4ded309c111a92b7a9e2910
[5/6] ARM: dts: rockchip: Add Luckfox Lyra Ultra board
      commit: db7c31e8a3341691fede23df4abc66c6aff37396
[6/6] ARM: dts: rockchip: Add Luckfox Lyra Zero W board
      commit: ad85370024767a4e79ef77e960b32e4e2bcffb68

Best regards,

Signature · 1 line
Heiko Stuebner <[email protected]>