Skip to contentSkip to conversation

board: rockchip: add Anbernic RG-DS

PATCH In review Chris Morgan 4 participants 5 messages May 10 – Jun 10

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

PATCH v3 1/1 board: rockchip: add Anbernic RG-DS

From: Chris Morgan <[email protected]>

Add support for the Anbernic RG-DS dual-screen handheld gaming device.

---
Changes since V1:
- Added entry to doc/board/rockchip/rockchip.rst.
- Removed &sdhci and added &vccio_sd to u-boot device tree.
- Added rk3568 to board path.
- Corrected defconfig and include files in MAINTAINERS.
- Removed CONFIG_EFI_LOADER, CONFIG_LEGACY_IMAGE_FORMAT, and CONFIG_DISABLE_CONSOLE from defconfig.
Changes since V2:
- Removed "clock-names" from CONFIG_OF_SPL_REMOVE_PROPS as after testing it appears it's no longer needed.
- Changed include to use rk3568-u-boot.dtsi instead of rk356x-u-boot.dtsi.
- Changed from CONFIG_NO_NET=y to "#CONFIG_NET is not set".

---
 .../arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi | 41 +++++++++++
 arch/arm/mach-rockchip/rk3568/Kconfig         |  7 ++
 board/anbernic/rg-ds_rk3568/Kconfig           | 12 +++
 board/anbernic/rg-ds_rk3568/MAINTAINERS       |  7 ++
 configs/anbernic-rg-ds-rk3568_defconfig       | 73 +++++++++++++++++++
 doc/board/rockchip/rockchip.rst               |  1 +
 include/configs/anbernic-rg-ds-rk3568.h       | 12 +++
 7 files changed, 153 insertions(+)
 create mode 100644 arch/arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi
 create mode 100644 board/anbernic/rg-ds_rk3568/Kconfig
 create mode 100644 board/anbernic/rg-ds_rk3568/MAINTAINERS
 create mode 100644 configs/anbernic-rg-ds-rk3568_defconfig
 create mode 100644 include/configs/anbernic-rg-ds-rk3568.h
arch/arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi new file +41 -0
new file mode 100644
index 00000000000..7944610827f
@@ -0,0 +1,41 @@
+// SPDX-License-Identifier: GPL-2.0+
+
+#include "rk3568-u-boot.dtsi"
+
+&gpio0 {
+	bootph-pre-ram;
+};
+
+&i2c0 {
+	bootph-pre-ram;
+};
+
+&i2c0_xfer {
+	bootph-pre-ram;
+};
+
+&i2s1m0_mclk {
+	bootph-pre-ram;
+};
+
+&pmic_int_l {
+	bootph-pre-ram;
+};
+
+&rk817 {
+	regulators {
+		bootph-pre-ram;
+	};
+};
+
+&sdmmc_pwren_l {
+	bootph-pre-ram;
+};
+
+&vcc3v3_sd {
+	bootph-pre-ram;
+};
+
+&vccio_sd {
+	bootph-pre-ram;
+};
arch/arm/mach-rockchip/rk3568/Kconfig +7 -0
index 2730220a18e..ec22898137e 100644
@@ -8,6 +8,12 @@ config TARGET_EVB_RK3568
 	help
 	  RK3568 EVB is a evaluation board for Rockchp RK3568.
 
+config TARGET_ANBERNIC_RG_DS_RK3568
+	bool "Anbernic RG DS"
+	help
+	  Anbernic RG DS gaming device with Rockchip RK3568 and dual
+	  displays.
+
 config TARGET_ANBERNIC_RGXX3_RK3566
 	bool "Anbernic RGXX3"
 	help
@@ -71,6 +77,7 @@ config SYS_SOC
 	default "rk3568"
 
 source "board/rockchip/evb_rk3568/Kconfig"
+source "board/anbernic/rg-ds_rk3568/Kconfig"
 source "board/anbernic/rgxx3_rk3566/Kconfig"
 source "board/hardkernel/odroid_m1/Kconfig"
 source "board/hardkernel/odroid_m1s/Kconfig"
board/anbernic/rg-ds_rk3568/Kconfig new file +12 -0
new file mode 100644
index 00000000000..8676940651a
@@ -0,0 +1,12 @@
+if TARGET_RG_DS_RK3568
+
+config SYS_BOARD
+	default "rg-ds_rk3568"
+
+config SYS_VENDOR
+	default "anbernic"
+
+config SYS_CONFIG_NAME
+	default "anbernic-rg-ds-rk3568"
+
+endif
board/anbernic/rg-ds_rk3568/MAINTAINERS new file +7 -0
new file mode 100644
index 00000000000..7b9b546f7bc
@@ -0,0 +1,7 @@
+ANBERNIC-RG-DS-RK3568
+M:	Chris Morgan <[email protected]>
+S:	Maintained
+F:	arch/arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi
+F:	board/anbernic/rg-ds_rk3568
+F:	configs/anbernic-rg-ds-rk3568_defconfig
+F:	include/configs/anbernic-rg-ds-rk3568.h
configs/anbernic-rg-ds-rk3568_defconfig new file +73 -0

73 lines not on this page · raw message

doc/board/rockchip/rockchip.rst +1 -0
index 141071f528a..faccba4289b 100644
@@ -126,6 +126,7 @@ List of mainline supported Rockchip boards:
      - Xunlong Orange Pi 3B (orangepi-3b-rk3566)
 
 * rk3568
+     - Anbernic RG-DS (anbernic-rg-ds-rk3568)
      - Rockchip Evb-RK3568 (evb-rk3568)
      - Banana Pi BPI-R2 Pro (bpi-r2-pro-rk3568)
      - EmbedFire LubanCat 2 (lubancat-2-rk3568)
include/configs/anbernic-rg-ds-rk3568.h new file +12 -0
new file mode 100644
index 00000000000..3c5bed952ef
@@ -0,0 +1,12 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+
+#ifndef __ANBERNIC_RG_DS_RK3568_H
+#define __ANBERNIC_RG_DS_RK3568_H
+
+#define ROCKCHIP_DEVICE_SETTINGS \
+			"stdout=serial,vidconsole\0" \
+			"stderr=serial,vidconsole\0"
+
+#include <configs/rk3568_common.h>
+
+#endif
Signature · 1 line
2.43.0
Reviewed-by on v3 1/1
#2 lore raw
In reply to Chris Morgan
Quoted 10 lines

2026年5月11日 05:17,Chris Morgan <[email protected]> 写道:

From: Chris Morgan <[email protected]>

Add support for the Anbernic RG-DS dual-screen handheld gaming device.

Thanks,
- Kever

Quoted 246 lines

---
Changes since V1:
- Added entry to doc/board/rockchip/rockchip.rst.
- Removed &sdhci and added &vccio_sd to u-boot device tree.
- Added rk3568 to board path.
- Corrected defconfig and include files in MAINTAINERS.
- Removed CONFIG_EFI_LOADER, CONFIG_LEGACY_IMAGE_FORMAT, and CONFIG_DISABLE_CONSOLE from defconfig.
Changes since V2:
- Removed "clock-names" from CONFIG_OF_SPL_REMOVE_PROPS as after testing it appears it's no longer needed.
- Changed include to use rk3568-u-boot.dtsi instead of rk356x-u-boot.dtsi.
- Changed from CONFIG_NO_NET=y to "#CONFIG_NET is not set".
---

.../arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi | 41 +++++++++++
arch/arm/mach-rockchip/rk3568/Kconfig         |  7 ++
board/anbernic/rg-ds_rk3568/Kconfig           | 12 +++
board/anbernic/rg-ds_rk3568/MAINTAINERS       |  7 ++
configs/anbernic-rg-ds-rk3568_defconfig       | 73 +++++++++++++++++++
doc/board/rockchip/rockchip.rst               |  1 +
include/configs/anbernic-rg-ds-rk3568.h       | 12 +++
7 files changed, 153 insertions(+)

create mode 100644 arch/arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi create mode 100644 board/anbernic/rg-ds_rk3568/Kconfig create mode 100644 board/anbernic/rg-ds_rk3568/MAINTAINERS create mode 100644 configs/anbernic-rg-ds-rk3568_defconfig create mode 100644 include/configs/anbernic-rg-ds-rk3568.h

arch/arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi new file +41 -0
new file mode 100644
index 00000000000..7944610827f
@@ -0,0 +1,41 @@
+// SPDX-License-Identifier: GPL-2.0+
+
+#include "rk3568-u-boot.dtsi"
+
+&gpio0 {
+	bootph-pre-ram;
+};
+
+&i2c0 {
+	bootph-pre-ram;
+};
+
+&i2c0_xfer {
+	bootph-pre-ram;
+};
+
+&i2s1m0_mclk {
+	bootph-pre-ram;
+};
+
+&pmic_int_l {
+	bootph-pre-ram;
+};
+
+&rk817 {
+	regulators {
+		bootph-pre-ram;
+	};
+};
+
+&sdmmc_pwren_l {
+	bootph-pre-ram;
+};
+
+&vcc3v3_sd {
+	bootph-pre-ram;
+};
+
+&vccio_sd {
+	bootph-pre-ram;
+};
arch/arm/mach-rockchip/rk3568/Kconfig +6 -0
index 2730220a18e..ec22898137e 100644
@@ -8,6 +8,12 @@ config TARGET_EVB_RK3568
 	help
 	  RK3568 EVB is a evaluation board for Rockchp RK3568.
 
+config TARGET_ANBERNIC_RG_DS_RK3568
+	bool "Anbernic RG DS"
+	help
+	  Anbernic RG DS gaming device with Rockchip RK3568 and dual
+	  displays.
+

config TARGET_ANBERNIC_RGXX3_RK3566
bool "Anbernic RGXX3"
help

arch/arm/mach-rockchip/rk3568/Kconfig +0 -0
@@ -71,6 +77,7 @@ config SYS_SOC
 	default "rk3568"
 

source "board/rockchip/evb_rk3568/Kconfig"
+source "board/anbernic/rg-ds_rk3568/Kconfig"
source "board/anbernic/rgxx3_rk3566/Kconfig"
source "board/hardkernel/odroid_m1/Kconfig"
source "board/hardkernel/odroid_m1s/Kconfig"

board/anbernic/rg-ds_rk3568/Kconfig new file +12 -0
new file mode 100644
index 00000000000..8676940651a
@@ -0,0 +1,12 @@
+if TARGET_RG_DS_RK3568
+
+config SYS_BOARD
+	default "rg-ds_rk3568"
+
+config SYS_VENDOR
+	default "anbernic"
+
+config SYS_CONFIG_NAME
+	default "anbernic-rg-ds-rk3568"
+
+endif
board/anbernic/rg-ds_rk3568/MAINTAINERS new file +7 -0
new file mode 100644
index 00000000000..7b9b546f7bc
@@ -0,0 +1,7 @@
+ANBERNIC-RG-DS-RK3568
+M:	Chris Morgan <[email protected]>
+S:	Maintained
+F:	arch/arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi
+F:	board/anbernic/rg-ds_rk3568
+F:	configs/anbernic-rg-ds-rk3568_defconfig
+F:	include/configs/anbernic-rg-ds-rk3568.h
configs/anbernic-rg-ds-rk3568_defconfig new file +73 -0
new file mode 100644
index 00000000000..399a216a7c9
@@ -0,0 +1,73 @@
+CONFIG_ARM=y
+CONFIG_SKIP_LOWLEVEL_INIT=y
+CONFIG_COUNTER_FREQUENCY=24000000
+CONFIG_ARCH_ROCKCHIP=y
+CONFIG_SPL_GPIO=y
+CONFIG_DEFAULT_DEVICE_TREE="rockchip/rk3568-anbernic-rg-ds"
+CONFIG_ROCKCHIP_RK3568=y
+CONFIG_ROCKCHIP_RK8XX_DISABLE_BOOT_ON_POWERON=y
+CONFIG_SPL_SERIAL=y
+CONFIG_TARGET_ANBERNIC_RG_DS_RK3568=y
+CONFIG_SYS_LOAD_ADDR=0xc00800
+CONFIG_DEBUG_UART_BASE=0xFE660000
+CONFIG_DEBUG_UART_CLOCK=24000000
+CONFIG_DEBUG_UART=y
+CONFIG_FIT=y
+CONFIG_FIT_VERBOSE=y
+CONFIG_SPL_FIT_SIGNATURE=y
+CONFIG_SPL_LOAD_FIT=y
+CONFIG_OF_STDOUT_VIA_ALIAS=y
+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-anbernic-rg-ds.dtb"
+# CONFIG_CONSOLE_MUX is not set
+CONFIG_BOARD_TYPES=y
+# CONFIG_DISPLAY_CPUINFO is not set
+CONFIG_DISPLAY_BOARDINFO_LATE=y
+CONFIG_BOARD_RNG_SEED=y
+CONFIG_SPL_MAX_SIZE=0x40000
+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
+CONFIG_SPL_POWER=y
+CONFIG_SPL_ATF=y
+CONFIG_CMD_PWM=y
+CONFIG_CMD_GPT=y
+CONFIG_CMD_MMC=y
+# CONFIG_CMD_SETEXPR is not set
+# CONFIG_CMD_CLS is not set
+# CONFIG_SPL_DOS_PARTITION is not set
+CONFIG_SPL_OF_CONTROL=y
+CONFIG_OF_LIVE=y
+CONFIG_OF_LIST="rockchip/rk3568-anbernic-rg-ds"
+CONFIG_OF_SPL_REMOVE_PROPS="interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents"
+CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
+# CONFIG_NET is not set
+CONFIG_SPL_DM_SEQ_ALIAS=y
+CONFIG_SPL_REGMAP=y
+CONFIG_SPL_SYSCON=y
+CONFIG_SPL_ADC=y
+CONFIG_SPL_CLK=y
+CONFIG_ROCKCHIP_GPIO=y
+CONFIG_SYS_I2C_ROCKCHIP=y
+CONFIG_MISC=y
+CONFIG_SUPPORT_EMMC_RPMB=y
+CONFIG_MMC_DW=y
+CONFIG_MMC_DW_ROCKCHIP=y
+CONFIG_MMC_SDHCI=y
+CONFIG_MMC_SDHCI_SDMA=y
+CONFIG_MMC_SDHCI_ROCKCHIP=y
+CONFIG_SPL_PINCTRL=y
+CONFIG_DM_PMIC=y
+CONFIG_DM_PMIC_FAN53555=y
+CONFIG_PMIC_RK8XX=y
+CONFIG_SPL_DM_REGULATOR=y
+CONFIG_SPL_DM_REGULATOR_FIXED=y
+CONFIG_REGULATOR_RK8XX=y
+CONFIG_PWM_ROCKCHIP=y
+CONFIG_SPL_RAM=y
+# CONFIG_RAM_ROCKCHIP_DEBUG is not set
+CONFIG_BAUDRATE=1500000
+# CONFIG_REQUIRE_SERIAL_CONSOLE is not set
+CONFIG_DEBUG_UART_SHIFT=2
+CONFIG_SYS_NS16550_MEM32=y
+CONFIG_SYSRESET=y
+CONFIG_REGEX=y
+# CONFIG_RSA is not set
+CONFIG_ERRNO_STR=y
doc/board/rockchip/rockchip.rst +1 -0
index 141071f528a..faccba4289b 100644
@@ -126,6 +126,7 @@ List of mainline supported Rockchip boards:
     - Xunlong Orange Pi 3B (orangepi-3b-rk3566)
 
 * rk3568
+     - Anbernic RG-DS (anbernic-rg-ds-rk3568)
     - Rockchip Evb-RK3568 (evb-rk3568)
     - Banana Pi BPI-R2 Pro (bpi-r2-pro-rk3568)
     - EmbedFire LubanCat 2 (lubancat-2-rk3568)
include/configs/anbernic-rg-ds-rk3568.h new file +12 -0
new file mode 100644
index 00000000000..3c5bed952ef
@@ -0,0 +1,12 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+
+#ifndef __ANBERNIC_RG_DS_RK3568_H
+#define __ANBERNIC_RG_DS_RK3568_H
+
+#define ROCKCHIP_DEVICE_SETTINGS \
+			"stdout=serial,vidconsole\0" \
+			"stderr=serial,vidconsole\0"
+
+#include <configs/rk3568_common.h>
+
+#endif
Signature · 1 line
2.43.0
#3 lore raw
In reply to Chris Morgan

Hi Chris,

Quoted 115 lines

2026年5月11日 05:17,Chris Morgan <[email protected]> 写道:

From: Chris Morgan <[email protected]>

Add support for the Anbernic RG-DS dual-screen handheld gaming device.

---
Changes since V1:
- Added entry to doc/board/rockchip/rockchip.rst.
- Removed &sdhci and added &vccio_sd to u-boot device tree.
- Added rk3568 to board path.
- Corrected defconfig and include files in MAINTAINERS.
- Removed CONFIG_EFI_LOADER, CONFIG_LEGACY_IMAGE_FORMAT, and CONFIG_DISABLE_CONSOLE from defconfig.
Changes since V2:
- Removed "clock-names" from CONFIG_OF_SPL_REMOVE_PROPS as after testing it appears it's no longer needed.
- Changed include to use rk3568-u-boot.dtsi instead of rk356x-u-boot.dtsi.
- Changed from CONFIG_NO_NET=y to "#CONFIG_NET is not set".
---

.../arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi | 41 +++++++++++
arch/arm/mach-rockchip/rk3568/Kconfig         |  7 ++
board/anbernic/rg-ds_rk3568/Kconfig           | 12 +++
board/anbernic/rg-ds_rk3568/MAINTAINERS       |  7 ++
configs/anbernic-rg-ds-rk3568_defconfig       | 73 +++++++++++++++++++
doc/board/rockchip/rockchip.rst               |  1 +
include/configs/anbernic-rg-ds-rk3568.h       | 12 +++
7 files changed, 153 insertions(+)

create mode 100644 arch/arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi create mode 100644 board/anbernic/rg-ds_rk3568/Kconfig create mode 100644 board/anbernic/rg-ds_rk3568/MAINTAINERS create mode 100644 configs/anbernic-rg-ds-rk3568_defconfig create mode 100644 include/configs/anbernic-rg-ds-rk3568.h

arch/arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi new file +41 -0
new file mode 100644
index 00000000000..7944610827f
@@ -0,0 +1,41 @@
+// SPDX-License-Identifier: GPL-2.0+
+
+#include "rk3568-u-boot.dtsi"
+
+&gpio0 {
+ bootph-pre-ram;
+};
+
+&i2c0 {
+ bootph-pre-ram;
+};
+
+&i2c0_xfer {
+ bootph-pre-ram;
+};
+
+&i2s1m0_mclk {
+ bootph-pre-ram;
+};
+
+&pmic_int_l {
+ bootph-pre-ram;
+};
+
+&rk817 {
+ regulators {
+ bootph-pre-ram;
+ };
+};
+
+&sdmmc_pwren_l {
+ bootph-pre-ram;
+};
+
+&vcc3v3_sd {
+ bootph-pre-ram;
+};
+
+&vccio_sd {
+ bootph-pre-ram;
+};
arch/arm/mach-rockchip/rk3568/Kconfig +0 -0
index 2730220a18e..ec22898137e 100644
@@ -8,6 +8,12 @@ config TARGET_EVB_RK3568

help
RK3568 EVB is a evaluation board for Rockchp RK3568.

arch/arm/mach-rockchip/rk3568/Kconfig +6 -0
+config TARGET_ANBERNIC_RG_DS_RK3568
+ bool "Anbernic RG DS"
+ help
+  Anbernic RG DS gaming device with Rockchip RK3568 and dual
+  displays.
+

config TARGET_ANBERNIC_RGXX3_RK3566
bool "Anbernic RGXX3"
help

arch/arm/mach-rockchip/rk3568/Kconfig +0 -0
@@ -71,6 +77,7 @@ config SYS_SOC

default "rk3568"

source "board/rockchip/evb_rk3568/Kconfig"
+source "board/anbernic/rg-ds_rk3568/Kconfig"
source "board/anbernic/rgxx3_rk3566/Kconfig"
source "board/hardkernel/odroid_m1/Kconfig"
source "board/hardkernel/odroid_m1s/Kconfig"

board/anbernic/rg-ds_rk3568/Kconfig new file +0 -0
new file mode 100644
index 00000000000..8676940651a

board/anbernic/rg-ds_rk3568/Kconfig line 1

Quoted 1 line
board/anbernic/rg-ds_rk3568/Kconfig new file +1 -0
@@ -0,0 +1,12 @@
+if TARGET_RG_DS_RK3568

This should be TARGET_ANBERNIC_RGXX3_RK3566 ?

Thanks,
- Kever

Quoted 138 lines
board/anbernic/rg-ds_rk3568/Kconfig new file +11 -0
+
+config SYS_BOARD
+ default "rg-ds_rk3568"
+
+config SYS_VENDOR
+ default "anbernic"
+
+config SYS_CONFIG_NAME
+ default "anbernic-rg-ds-rk3568"
+
+endif
board/anbernic/rg-ds_rk3568/MAINTAINERS new file +7 -0
new file mode 100644
index 00000000000..7b9b546f7bc
@@ -0,0 +1,7 @@
+ANBERNIC-RG-DS-RK3568
+M: Chris Morgan <[email protected]>
+S: Maintained
+F: arch/arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi
+F: board/anbernic/rg-ds_rk3568
+F: configs/anbernic-rg-ds-rk3568_defconfig
+F: include/configs/anbernic-rg-ds-rk3568.h
configs/anbernic-rg-ds-rk3568_defconfig new file +73 -0
new file mode 100644
index 00000000000..399a216a7c9
@@ -0,0 +1,73 @@
+CONFIG_ARM=y
+CONFIG_SKIP_LOWLEVEL_INIT=y
+CONFIG_COUNTER_FREQUENCY=24000000
+CONFIG_ARCH_ROCKCHIP=y
+CONFIG_SPL_GPIO=y
+CONFIG_DEFAULT_DEVICE_TREE="rockchip/rk3568-anbernic-rg-ds"
+CONFIG_ROCKCHIP_RK3568=y
+CONFIG_ROCKCHIP_RK8XX_DISABLE_BOOT_ON_POWERON=y
+CONFIG_SPL_SERIAL=y
+CONFIG_TARGET_ANBERNIC_RG_DS_RK3568=y
+CONFIG_SYS_LOAD_ADDR=0xc00800
+CONFIG_DEBUG_UART_BASE=0xFE660000
+CONFIG_DEBUG_UART_CLOCK=24000000
+CONFIG_DEBUG_UART=y
+CONFIG_FIT=y
+CONFIG_FIT_VERBOSE=y
+CONFIG_SPL_FIT_SIGNATURE=y
+CONFIG_SPL_LOAD_FIT=y
+CONFIG_OF_STDOUT_VIA_ALIAS=y
+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-anbernic-rg-ds.dtb"
+# CONFIG_CONSOLE_MUX is not set
+CONFIG_BOARD_TYPES=y
+# CONFIG_DISPLAY_CPUINFO is not set
+CONFIG_DISPLAY_BOARDINFO_LATE=y
+CONFIG_BOARD_RNG_SEED=y
+CONFIG_SPL_MAX_SIZE=0x40000
+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
+CONFIG_SPL_POWER=y
+CONFIG_SPL_ATF=y
+CONFIG_CMD_PWM=y
+CONFIG_CMD_GPT=y
+CONFIG_CMD_MMC=y
+# CONFIG_CMD_SETEXPR is not set
+# CONFIG_CMD_CLS is not set
+# CONFIG_SPL_DOS_PARTITION is not set
+CONFIG_SPL_OF_CONTROL=y
+CONFIG_OF_LIVE=y
+CONFIG_OF_LIST="rockchip/rk3568-anbernic-rg-ds"
+CONFIG_OF_SPL_REMOVE_PROPS="interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents"
+CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
+# CONFIG_NET is not set
+CONFIG_SPL_DM_SEQ_ALIAS=y
+CONFIG_SPL_REGMAP=y
+CONFIG_SPL_SYSCON=y
+CONFIG_SPL_ADC=y
+CONFIG_SPL_CLK=y
+CONFIG_ROCKCHIP_GPIO=y
+CONFIG_SYS_I2C_ROCKCHIP=y
+CONFIG_MISC=y
+CONFIG_SUPPORT_EMMC_RPMB=y
+CONFIG_MMC_DW=y
+CONFIG_MMC_DW_ROCKCHIP=y
+CONFIG_MMC_SDHCI=y
+CONFIG_MMC_SDHCI_SDMA=y
+CONFIG_MMC_SDHCI_ROCKCHIP=y
+CONFIG_SPL_PINCTRL=y
+CONFIG_DM_PMIC=y
+CONFIG_DM_PMIC_FAN53555=y
+CONFIG_PMIC_RK8XX=y
+CONFIG_SPL_DM_REGULATOR=y
+CONFIG_SPL_DM_REGULATOR_FIXED=y
+CONFIG_REGULATOR_RK8XX=y
+CONFIG_PWM_ROCKCHIP=y
+CONFIG_SPL_RAM=y
+# CONFIG_RAM_ROCKCHIP_DEBUG is not set
+CONFIG_BAUDRATE=1500000
+# CONFIG_REQUIRE_SERIAL_CONSOLE is not set
+CONFIG_DEBUG_UART_SHIFT=2
+CONFIG_SYS_NS16550_MEM32=y
+CONFIG_SYSRESET=y
+CONFIG_REGEX=y
+# CONFIG_RSA is not set
+CONFIG_ERRNO_STR=y
doc/board/rockchip/rockchip.rst +1 -0
index 141071f528a..faccba4289b 100644
@@ -126,6 +126,7 @@ List of mainline supported Rockchip boards:
     - Xunlong Orange Pi 3B (orangepi-3b-rk3566)
 
 * rk3568
+     - Anbernic RG-DS (anbernic-rg-ds-rk3568)
     - Rockchip Evb-RK3568 (evb-rk3568)
     - Banana Pi BPI-R2 Pro (bpi-r2-pro-rk3568)
     - EmbedFire LubanCat 2 (lubancat-2-rk3568)
include/configs/anbernic-rg-ds-rk3568.h new file +12 -0
new file mode 100644
index 00000000000..3c5bed952ef
@@ -0,0 +1,12 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+
+#ifndef __ANBERNIC_RG_DS_RK3568_H
+#define __ANBERNIC_RG_DS_RK3568_H
+
+#define ROCKCHIP_DEVICE_SETTINGS \
+ "stdout=serial,vidconsole\0" \
+ "stderr=serial,vidconsole\0"
+
+#include <configs/rk3568_common.h>
+
+#endif
Signature · 1 line
2.43.0
#4 lore raw
Quoted 107 lines · Kever Yang

Hi Chris,

Quoted 104 lines

2026年5月11日 05:17,Chris Morgan <[email protected]> 写道:

From: Chris Morgan <[email protected]>

Add support for the Anbernic RG-DS dual-screen handheld gaming device.

---
Changes since V1:
- Added entry to doc/board/rockchip/rockchip.rst.
- Removed &sdhci and added &vccio_sd to u-boot device tree.
- Added rk3568 to board path.
- Corrected defconfig and include files in MAINTAINERS.
- Removed CONFIG_EFI_LOADER, CONFIG_LEGACY_IMAGE_FORMAT, and CONFIG_DISABLE_CONSOLE from defconfig.
Changes since V2:
- Removed "clock-names" from CONFIG_OF_SPL_REMOVE_PROPS as after testing it appears it's no longer needed.
- Changed include to use rk3568-u-boot.dtsi instead of rk356x-u-boot.dtsi.
- Changed from CONFIG_NO_NET=y to "#CONFIG_NET is not set".
---

.../arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi | 41 +++++++++++
arch/arm/mach-rockchip/rk3568/Kconfig         |  7 ++
board/anbernic/rg-ds_rk3568/Kconfig           | 12 +++
board/anbernic/rg-ds_rk3568/MAINTAINERS       |  7 ++
configs/anbernic-rg-ds-rk3568_defconfig       | 73 +++++++++++++++++++
doc/board/rockchip/rockchip.rst               |  1 +
include/configs/anbernic-rg-ds-rk3568.h       | 12 +++
7 files changed, 153 insertions(+)

create mode 100644 arch/arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi create mode 100644 board/anbernic/rg-ds_rk3568/Kconfig create mode 100644 board/anbernic/rg-ds_rk3568/MAINTAINERS create mode 100644 configs/anbernic-rg-ds-rk3568_defconfig create mode 100644 include/configs/anbernic-rg-ds-rk3568.h

arch/arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi new file +41 -0
new file mode 100644
index 00000000000..7944610827f
@@ -0,0 +1,41 @@
+// SPDX-License-Identifier: GPL-2.0+
+
+#include "rk3568-u-boot.dtsi"
+
+&gpio0 {
+ bootph-pre-ram;
+};
+
+&i2c0 {
+ bootph-pre-ram;
+};
+
+&i2c0_xfer {
+ bootph-pre-ram;
+};
+
+&i2s1m0_mclk {
+ bootph-pre-ram;
+};
+
+&pmic_int_l {
+ bootph-pre-ram;
+};
+
+&rk817 {
+ regulators {
+ bootph-pre-ram;
+ };
+};
+
+&sdmmc_pwren_l {
+ bootph-pre-ram;
+};
+
+&vcc3v3_sd {
+ bootph-pre-ram;
+};
+
+&vccio_sd {
+ bootph-pre-ram;
+};
arch/arm/mach-rockchip/rk3568/Kconfig +0 -0
index 2730220a18e..ec22898137e 100644
@@ -8,6 +8,12 @@ config TARGET_EVB_RK3568

help
RK3568 EVB is a evaluation board for Rockchp RK3568.

arch/arm/mach-rockchip/rk3568/Kconfig +6 -0
+config TARGET_ANBERNIC_RG_DS_RK3568
+ bool "Anbernic RG DS"
+ help
+  Anbernic RG DS gaming device with Rockchip RK3568 and dual
+  displays.
+

config TARGET_ANBERNIC_RGXX3_RK3566
bool "Anbernic RGXX3"
help

arch/arm/mach-rockchip/rk3568/Kconfig +0 -0
@@ -71,6 +77,7 @@ config SYS_SOC

default "rk3568"

Quoted 14 lines

board/anbernic/rg-ds_rk3568/Kconfig line 1

Quoted 12 lines

source "board/rockchip/evb_rk3568/Kconfig"
+source "board/anbernic/rg-ds_rk3568/Kconfig"
source "board/anbernic/rgxx3_rk3566/Kconfig"
source "board/hardkernel/odroid_m1/Kconfig"
source "board/hardkernel/odroid_m1s/Kconfig"

board/anbernic/rg-ds_rk3568/Kconfig new file +1 -0
new file mode 100644
index 00000000000..8676940651a
@@ -0,0 +1,12 @@
+if TARGET_RG_DS_RK3568

This should be TARGET_ANBERNIC_RGXX3_RK3566 ?

No, sadly this board reuses an ADC value from the RGxx3 series so it requires its own U-Boot. It may be possible to detect the CPU at runtime and apply a different table (since this device is an RK3568 instead of an RK3566 like the rest), but I have not done that as of this time.

Thank you,
Chris

Quoted 142 lines

Thanks,
- Kever

Quoted 138 lines
board/anbernic/rg-ds_rk3568/Kconfig new file +11 -0
+
+config SYS_BOARD
+ default "rg-ds_rk3568"
+
+config SYS_VENDOR
+ default "anbernic"
+
+config SYS_CONFIG_NAME
+ default "anbernic-rg-ds-rk3568"
+
+endif
board/anbernic/rg-ds_rk3568/MAINTAINERS new file +7 -0
new file mode 100644
index 00000000000..7b9b546f7bc
@@ -0,0 +1,7 @@
+ANBERNIC-RG-DS-RK3568
+M: Chris Morgan <[email protected]>
+S: Maintained
+F: arch/arm/dts/rk3568-anbernic-rg-ds-u-boot.dtsi
+F: board/anbernic/rg-ds_rk3568
+F: configs/anbernic-rg-ds-rk3568_defconfig
+F: include/configs/anbernic-rg-ds-rk3568.h
configs/anbernic-rg-ds-rk3568_defconfig new file +73 -0
new file mode 100644
index 00000000000..399a216a7c9
@@ -0,0 +1,73 @@
+CONFIG_ARM=y
+CONFIG_SKIP_LOWLEVEL_INIT=y
+CONFIG_COUNTER_FREQUENCY=24000000
+CONFIG_ARCH_ROCKCHIP=y
+CONFIG_SPL_GPIO=y
+CONFIG_DEFAULT_DEVICE_TREE="rockchip/rk3568-anbernic-rg-ds"
+CONFIG_ROCKCHIP_RK3568=y
+CONFIG_ROCKCHIP_RK8XX_DISABLE_BOOT_ON_POWERON=y
+CONFIG_SPL_SERIAL=y
+CONFIG_TARGET_ANBERNIC_RG_DS_RK3568=y
+CONFIG_SYS_LOAD_ADDR=0xc00800
+CONFIG_DEBUG_UART_BASE=0xFE660000
+CONFIG_DEBUG_UART_CLOCK=24000000
+CONFIG_DEBUG_UART=y
+CONFIG_FIT=y
+CONFIG_FIT_VERBOSE=y
+CONFIG_SPL_FIT_SIGNATURE=y
+CONFIG_SPL_LOAD_FIT=y
+CONFIG_OF_STDOUT_VIA_ALIAS=y
+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-anbernic-rg-ds.dtb"
+# CONFIG_CONSOLE_MUX is not set
+CONFIG_BOARD_TYPES=y
+# CONFIG_DISPLAY_CPUINFO is not set
+CONFIG_DISPLAY_BOARDINFO_LATE=y
+CONFIG_BOARD_RNG_SEED=y
+CONFIG_SPL_MAX_SIZE=0x40000
+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
+CONFIG_SPL_POWER=y
+CONFIG_SPL_ATF=y
+CONFIG_CMD_PWM=y
+CONFIG_CMD_GPT=y
+CONFIG_CMD_MMC=y
+# CONFIG_CMD_SETEXPR is not set
+# CONFIG_CMD_CLS is not set
+# CONFIG_SPL_DOS_PARTITION is not set
+CONFIG_SPL_OF_CONTROL=y
+CONFIG_OF_LIVE=y
+CONFIG_OF_LIST="rockchip/rk3568-anbernic-rg-ds"
+CONFIG_OF_SPL_REMOVE_PROPS="interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents"
+CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
+# CONFIG_NET is not set
+CONFIG_SPL_DM_SEQ_ALIAS=y
+CONFIG_SPL_REGMAP=y
+CONFIG_SPL_SYSCON=y
+CONFIG_SPL_ADC=y
+CONFIG_SPL_CLK=y
+CONFIG_ROCKCHIP_GPIO=y
+CONFIG_SYS_I2C_ROCKCHIP=y
+CONFIG_MISC=y
+CONFIG_SUPPORT_EMMC_RPMB=y
+CONFIG_MMC_DW=y
+CONFIG_MMC_DW_ROCKCHIP=y
+CONFIG_MMC_SDHCI=y
+CONFIG_MMC_SDHCI_SDMA=y
+CONFIG_MMC_SDHCI_ROCKCHIP=y
+CONFIG_SPL_PINCTRL=y
+CONFIG_DM_PMIC=y
+CONFIG_DM_PMIC_FAN53555=y
+CONFIG_PMIC_RK8XX=y
+CONFIG_SPL_DM_REGULATOR=y
+CONFIG_SPL_DM_REGULATOR_FIXED=y
+CONFIG_REGULATOR_RK8XX=y
+CONFIG_PWM_ROCKCHIP=y
+CONFIG_SPL_RAM=y
+# CONFIG_RAM_ROCKCHIP_DEBUG is not set
+CONFIG_BAUDRATE=1500000
+# CONFIG_REQUIRE_SERIAL_CONSOLE is not set
+CONFIG_DEBUG_UART_SHIFT=2
+CONFIG_SYS_NS16550_MEM32=y
+CONFIG_SYSRESET=y
+CONFIG_REGEX=y
+# CONFIG_RSA is not set
+CONFIG_ERRNO_STR=y
doc/board/rockchip/rockchip.rst +1 -0
index 141071f528a..faccba4289b 100644
@@ -126,6 +126,7 @@ List of mainline supported Rockchip boards:
     - Xunlong Orange Pi 3B (orangepi-3b-rk3566)
 
 * rk3568
+     - Anbernic RG-DS (anbernic-rg-ds-rk3568)
     - Rockchip Evb-RK3568 (evb-rk3568)
     - Banana Pi BPI-R2 Pro (bpi-r2-pro-rk3568)
     - EmbedFire LubanCat 2 (lubancat-2-rk3568)
include/configs/anbernic-rg-ds-rk3568.h new file +12 -0
new file mode 100644
index 00000000000..3c5bed952ef
@@ -0,0 +1,12 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+
+#ifndef __ANBERNIC_RG_DS_RK3568_H
+#define __ANBERNIC_RG_DS_RK3568_H
+
+#define ROCKCHIP_DEVICE_SETTINGS \
+ "stdout=serial,vidconsole\0" \
+ "stderr=serial,vidconsole\0"
+
+#include <configs/rk3568_common.h>
+
+#endif
Signature · 1 line
2.43.0