]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
rockchip: Add support for Radxa ROCK 4C+
authorFUKAUMI Naoki <naoki@radxa.com>
Wed, 29 Jan 2025 07:33:59 +0000 (07:33 +0000)
committerHauke Mehrtens <hauke@hauke-m.de>
Thu, 4 Sep 2025 21:55:53 +0000 (23:55 +0200)
The Radxa ROCK 4C+[1] is a single board computer with dual HDMI using
the Rockchip RK3399-T.

Hardware
--------

- Dual-core Cortex-A72 and quad-core Cortex-A53 CPU
- Mali-T860MP4 GPU
- LPDDR4 4GB RAM
- eMMC connector
- microSD card slot
- Wi-Fi 5 (not supported)
- Gigabit Ethernet with PoE support (additional PoE HAT required)
- USB 3.0 Type-A OTG port
- USB 3.0 Type-A HOST port
- 2x USB 2.0 Type-A HOST ports
- USB Type-C power port (5V only)
- 40 Pin GPIO header

[1] https://radxa.com/products/rock4/4cp

Installation
------------
Uncompress the OpenWrt sysupgrade and write it to the micro SD card or
internal eMMC using dd.

Signed-off-by: FUKAUMI Naoki <naoki@radxa.com>
Link: https://github.com/openwrt/openwrt/pull/17554
(cherry picked from commit 18925614c01c1e2283a283244c58c65b2502ae45)
Link: https://github.com/openwrt/openwrt/pull/19940
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
package/boot/uboot-rockchip/Makefile
target/linux/rockchip/image/armv8.mk
target/linux/rockchip/patches-6.6/129-rock-4c-plus-add-led-aliases-and-stop-heartbeat.patch [new file with mode: 0644]

index 7070ca973d3200a37d3305b191032afcc8a17d4b..046982c847c1fc8d2fece8edaed12d9118007ea4 100644 (file)
@@ -136,6 +136,13 @@ define U-Boot/nanopi-r4s-rk3399
     friendlyarm_nanopi-r4s-enterprise
 endef
 
+define U-Boot/rock-4c-plus-rk3399
+  $(U-Boot/rk3399/Default)
+  NAME:=ROCK 4C+
+  BUILD_DEVICES:= \
+    radxa_rock-4c-plus
+endef
+
 define U-Boot/rock-pi-4-rk3399
   $(U-Boot/rk3399/Default)
   NAME:=Rock Pi 4
@@ -300,6 +307,7 @@ endef
 UBOOT_TARGETS := \
   nanopc-t4-rk3399 \
   nanopi-r4s-rk3399 \
+  rock-4c-plus-rk3399 \
   rock-pi-4-rk3399 \
   rockpro64-rk3399 \
   rock-pi-s-rk3308 \
index 1c81005f8ea623ed09c3fa00a74be5a343ab5443..ed1eb3f5cd3603fd8dc945bb782381a45d3ef054 100644 (file)
@@ -183,6 +183,13 @@ define Device/radxa_rock-3c
 endef
 TARGET_DEVICES += radxa_rock-3c
 
+define Device/radxa_rock-4c-plus
+  DEVICE_VENDOR := Radxa
+  DEVICE_MODEL := ROCK 4C+
+  SOC := rk3399
+endef
+TARGET_DEVICES += radxa_rock-4c-plus
+
 define Device/radxa_rock-5a
   DEVICE_VENDOR := Radxa
   DEVICE_MODEL := ROCK 5A
diff --git a/target/linux/rockchip/patches-6.6/129-rock-4c-plus-add-led-aliases-and-stop-heartbeat.patch b/target/linux/rockchip/patches-6.6/129-rock-4c-plus-add-led-aliases-and-stop-heartbeat.patch
new file mode 100644 (file)
index 0000000..a9fbf0e
--- /dev/null
@@ -0,0 +1,27 @@
+--- a/arch/arm64/boot/dts/rockchip/rk3399-rock-4c-plus.dts
++++ b/arch/arm64/boot/dts/rockchip/rk3399-rock-4c-plus.dts
+@@ -17,6 +17,10 @@
+       aliases {
+               mmc0 = &sdhci;
+               mmc1 = &sdmmc;
++              led-boot = &led_blue;
++              led-failsafe = &led_blue;
++              led-running = &led_blue;
++              led-upgrade = &led_blue;
+       };
+       chosen {
+@@ -44,11 +48,11 @@
+               };
+               /* USER_LED2 */
+-              led-1 {
++              led_blue: led-1 {
+                       function = LED_FUNCTION_STATUS;
+                       color = <LED_COLOR_ID_BLUE>;
++                      default-state = "on";
+                       gpios = <&gpio3 RK_PD5 GPIO_ACTIVE_HIGH>;
+-                      linux,default-trigger = "heartbeat";
+               };
+       };