Skip to contentSkip to conversation

arm64: dts: rockchip: Add ROCKPi 4A/4B support

PATCH Superseded Jagan Teki 2 participants 4 messages Jul 20, 2020 – Jul 21, 2020

Subsystems (2)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Jagan Teki

author
#0 lore raw

PATCH 1/2 arm64: dts: rockchip: Add ROCKPi 4A/4B support

Rock PI 4 has 3 variants of hardware platforms called RockPI 4A, 4B, and 4C.

- Rock PI 4A has no Wif/BT.
- Rock PI 4B has AP6256 Wifi/BT, PoE.
- Rock PI 4C has AP6256 Wifi/BT, PoE, miniDP, USB Host enable GPIO pin change compared to 4B, 4C

So move common nodes, properties into dtsi file and include on respective variant dts files.

Use 4B dts into default rock-pi-4 defconfig until we find any solution for dynamic detection of these variants.

---
Note: Linux dts changes on mailing-list
https://lkml.org/lkml/2020/7/20/443
https://lkml.org/lkml/2020/7/20/444

 arch/arm/dts/Makefile                         |  3 +-
 ...99-rock-pi-4.dts => rk3399-rock-pi-4.dtsi} | 26 ------------
 arch/arm/dts/rk3399-rock-pi-4a.dts            | 13 ++++++
 arch/arm/dts/rk3399-rock-pi-4b-u-boot.dtsi    |  6 +++
 arch/arm/dts/rk3399-rock-pi-4b.dts            | 42 +++++++++++++++++++
 configs/rock-pi-4-rk3399_defconfig            |  4 +-
 6 files changed, 65 insertions(+), 29 deletions(-)
 rename arch/arm/dts/{rk3399-rock-pi-4.dts => rk3399-rock-pi-4.dtsi} (95%)
 create mode 100644 arch/arm/dts/rk3399-rock-pi-4a.dts
 create mode 100644 arch/arm/dts/rk3399-rock-pi-4b-u-boot.dtsi
 create mode 100644 arch/arm/dts/rk3399-rock-pi-4b.dts
arch/arm/dts/Makefile +2 -1
index 82e9b18cb8..bcd89af6a5 100644
@@ -136,7 +136,8 @@ dtb-$(CONFIG_ROCKCHIP_RK3399) += \
 	rk3399-puma-haikou.dtb \
 	rk3399-roc-pc.dtb \
 	rk3399-roc-pc-mezzanine.dtb \
-	rk3399-rock-pi-4.dtb \
+	rk3399-rock-pi-4a.dtb \
+	rk3399-rock-pi-4b.dtb \
 	rk3399-rock960.dtb \
 	rk3399-rockpro64.dtb \
 	rk3399pro-rock-pi-n10.dtb
arch/arm/dts/rk3399-rock-pi-4.dtsi renamed from arch/arm/dts/rk3399-rock-pi-4.dts +0 -26
similarity index 95%
rename from arch/arm/dts/rk3399-rock-pi-4.dts
rename to arch/arm/dts/rk3399-rock-pi-4.dtsi
index 3923ec01ef..1c55a4645b 100644
@@ -11,9 +11,6 @@
 #include "rk3399-opp.dtsi"
 
 / {
-	model = "Radxa ROCK Pi 4";
-	compatible = "radxa,rockpi4", "rockchip,rk3399";
-
 	chosen {
 		stdout-path = "serial2:1500000n8";
 	};
@@ -587,17 +584,6 @@
 	pinctrl-names = "default";
 	pinctrl-0 = <&sdio0_bus4 &sdio0_cmd &sdio0_clk>;
 	sd-uhs-sdr104;
-	status = "okay";
-
-	brcmf: wifi@1 {
-		compatible = "brcm,bcm4329-fmac";
-		reg = <1>;
-		interrupt-parent = <&gpio0>;
-		interrupts = <RK_PA3 GPIO_ACTIVE_HIGH>;
-		interrupt-names = "host-wake";
-		pinctrl-names = "default";
-		pinctrl-0 = <&wifi_host_wake_l>;
-	};
 };
 
 &sdmmc {
@@ -666,18 +652,6 @@
 &uart0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&uart0_xfer &uart0_cts &uart0_rts>;
-	status = "okay";
-
-	bluetooth {
-		compatible = "brcm,bcm43438-bt";
-		clocks = <&rk808 1>;
-		clock-names = "ext_clock";
-		device-wakeup-gpios = <&gpio2 RK_PD3 GPIO_ACTIVE_HIGH>;
-		host-wakeup-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>;
-		shutdown-gpios = <&gpio0 RK_PB1 GPIO_ACTIVE_HIGH>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&bt_host_wake_l &bt_wake_l &bt_enable_h>;
-	};
 };
 
 &uart2 {
arch/arm/dts/rk3399-rock-pi-4a.dts new file +13 -0
new file mode 100644
index 0000000000..d96dd3ebd3
@@ -0,0 +1,13 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+/*
+ * Copyright (c) 2019 Akash Gajjar <[email protected]>
+ * Copyright (c) 2019 Pragnesh Patel <[email protected]>
+ */
+
+/dts-v1/;
+#include "rk3399-rock-pi-4.dtsi"
+
+/ {
+	model = "Radxa ROCK Pi 4A";
+	compatible = "radxa,rockpi4", "rockchip,rk3399";
+};
arch/arm/dts/rk3399-rock-pi-4b-u-boot.dtsi new file +6 -0
new file mode 100644
index 0000000000..85ee5770ad
@@ -0,0 +1,6 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2019 Jagan Teki <[email protected]>
+ */
+
+#include "rk3399-rock-pi-4-u-boot.dtsi"
arch/arm/dts/rk3399-rock-pi-4b.dts new file +42 -0

42 lines not on this page · raw message

configs/rock-pi-4-rk3399_defconfig +2 -2
index 98f71a50a5..1d34476825 100644
@@ -9,7 +9,7 @@ CONFIG_DEBUG_UART_BASE=0xFF1A0000
 CONFIG_DEBUG_UART_CLOCK=24000000
 CONFIG_DEBUG_UART=y
 # CONFIG_ANDROID_BOOT_IMAGE is not set
-CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rock-pi-4.dtb"
+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rock-pi-4b.dtb"
 CONFIG_MISC_INIT_R=y
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
@@ -24,7 +24,7 @@ CONFIG_CMD_USB=y
 # CONFIG_CMD_SETEXPR is not set
 CONFIG_CMD_TIME=y
 CONFIG_SPL_OF_CONTROL=y
-CONFIG_DEFAULT_DEVICE_TREE="rk3399-rock-pi-4"
+CONFIG_DEFAULT_DEVICE_TREE="rk3399-rock-pi-4b"
 CONFIG_OF_SPL_REMOVE_PROPS="pinctrl-0 pinctrl-names clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents"
 CONFIG_ENV_IS_IN_MMC=y
 CONFIG_SYS_RELOC_GD_ENV_ADDR=y
Signature · 1 line
2.25.1
author
#1 lore raw

PATCH 2/2 arm64: dts: rockchip: Add Radxa ROCK Pi 4C support

Rock PI 4C has AP6256 Wifi/BT, PoE, miniDP, USB Host enabled GPIO pin change compared to 4B, 4C.

So, add or enable difference nodes/properties in 4C dts by including common dtsi.

---
Note: Linux dts changes on mailing-list
https://lkml.org/lkml/2020/7/20/445

 arch/arm/dts/Makefile                      |  1 +
 arch/arm/dts/rk3399-rock-pi-4c-u-boot.dtsi |  6 ++
 arch/arm/dts/rk3399-rock-pi-4c.dts         | 51 +++++++++++++++
 board/rockchip/evb_rk3399/MAINTAINERS      |  2 +
 configs/rock-pi-4c-rk3399_defconfig        | 74 ++++++++++++++++++++++
 5 files changed, 134 insertions(+)
 create mode 100644 arch/arm/dts/rk3399-rock-pi-4c-u-boot.dtsi
 create mode 100644 arch/arm/dts/rk3399-rock-pi-4c.dts
 create mode 100644 configs/rock-pi-4c-rk3399_defconfig
arch/arm/dts/Makefile +1 -0
index bcd89af6a5..5726156a2d 100644
@@ -138,6 +138,7 @@ dtb-$(CONFIG_ROCKCHIP_RK3399) += \
 	rk3399-roc-pc-mezzanine.dtb \
 	rk3399-rock-pi-4a.dtb \
 	rk3399-rock-pi-4b.dtb \
+	rk3399-rock-pi-4c.dtb \
 	rk3399-rock960.dtb \
 	rk3399-rockpro64.dtb \
 	rk3399pro-rock-pi-n10.dtb
arch/arm/dts/rk3399-rock-pi-4c-u-boot.dtsi new file +6 -0
new file mode 100644
index 0000000000..85ee5770ad
@@ -0,0 +1,6 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2019 Jagan Teki <[email protected]>
+ */
+
+#include "rk3399-rock-pi-4-u-boot.dtsi"
arch/arm/dts/rk3399-rock-pi-4c.dts new file +51 -0

51 lines not on this page · raw message

board/rockchip/evb_rk3399/MAINTAINERS +2 -0
index 578638a58b..4c889e06a6 100644
@@ -68,6 +68,8 @@ M:	Jagan Teki <[email protected]>
 S:	Maintained
 F:	configs/rock-pi-4-rk3399_defconfig
 F:	arch/arm/dts/rk3399-rock-pi-4-u-boot.dtsi
+F:	configs/rock-pi-4c-rk3399_defconfig
+F:	arch/arm/dts/rk3399-rock-pi-4c-u-boot.dtsi
 
 ROCK-PI-N10
 M:	Jagan Teki <[email protected]>
configs/rock-pi-4c-rk3399_defconfig new file +74 -0

74 lines not on this page · raw message

Signature · 1 line
2.25.1
Reviewed-by on v1 2/2
#2 lore raw

Re: [PATCH 2/2] arm64: dts: rockchip: Add Radxa ROCK Pi 4C support

Quoted 7 lines · Jagan Teki

Rock PI 4C has AP6256 Wifi/BT, PoE, miniDP, USB Host enabled GPIO pin change compared to 4B, 4C.

So, add or enable difference nodes/properties in 4C dts by including common dtsi.

Thanks,
- Kever

Quoted 188 lines

---
Note: Linux dts changes on mailing-list
https://lkml.org/lkml/2020/7/20/445

  arch/arm/dts/Makefile                      |  1 +
  arch/arm/dts/rk3399-rock-pi-4c-u-boot.dtsi |  6 ++
  arch/arm/dts/rk3399-rock-pi-4c.dts         | 51 +++++++++++++++
  board/rockchip/evb_rk3399/MAINTAINERS      |  2 +
  configs/rock-pi-4c-rk3399_defconfig        | 74 ++++++++++++++++++++++
  5 files changed, 134 insertions(+)

create mode 100644 arch/arm/dts/rk3399-rock-pi-4c-u-boot.dtsi create mode 100644 arch/arm/dts/rk3399-rock-pi-4c.dts create mode 100644 configs/rock-pi-4c-rk3399_defconfig

arch/arm/dts/Makefile +1 -0
index bcd89af6a5..5726156a2d 100644
@@ -138,6 +138,7 @@ dtb-$(CONFIG_ROCKCHIP_RK3399) += \
  	rk3399-roc-pc-mezzanine.dtb \
  	rk3399-rock-pi-4a.dtb \
  	rk3399-rock-pi-4b.dtb \
+	rk3399-rock-pi-4c.dtb \
  	rk3399-rock960.dtb \
  	rk3399-rockpro64.dtb \
  	rk3399pro-rock-pi-n10.dtb
arch/arm/dts/rk3399-rock-pi-4c-u-boot.dtsi new file +6 -0
new file mode 100644
index 0000000000..85ee5770ad
@@ -0,0 +1,6 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2019 Jagan Teki <[email protected]>
+ */
+
+#include "rk3399-rock-pi-4-u-boot.dtsi"
arch/arm/dts/rk3399-rock-pi-4c.dts new file +51 -0
new file mode 100644
index 0000000000..9d07ebd1ec
@@ -0,0 +1,51 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+/*
+ * Copyright (c) 2019 Fuzhou Rockchip Electronics Co., Ltd
+ * Copyright (c) 2019 Radxa Limited
+ * Copyright (c) 2019 Amarula Solutions(India)
+ */
+
+/dts-v1/;
+#include "rk3399-rock-pi-4.dtsi"
+
+/ {
+	model = "Radxa ROCK Pi 4C";
+	compatible = "radxa,rockpi4", "rockchip,rk3399";
+};
+
+&sdio0 {
+	status = "okay";
+
+	brcmf: wifi@1 {
+		compatible = "brcm,bcm4329-fmac";
+		reg = <1>;
+		interrupt-parent = <&gpio0>;
+		interrupts = <RK_PA3 GPIO_ACTIVE_HIGH>;
+		interrupt-names = "host-wake";
+		pinctrl-names = "default";
+		pinctrl-0 = <&wifi_host_wake_l>;
+	};
+};
+
+&uart0 {
+	status = "okay";
+
+	bluetooth {
+		compatible = "brcm,bcm43438-bt";
+		clocks = <&rk808 1>;
+		clock-names = "ext_clock";
+		device-wakeup-gpios = <&gpio2 RK_PD3 GPIO_ACTIVE_HIGH>;
+		host-wakeup-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>;
+		shutdown-gpios = <&gpio0 RK_PB1 GPIO_ACTIVE_HIGH>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&bt_host_wake_l &bt_wake_l &bt_enable_h>;
+	};
+};
+
+&vcc5v0_host {
+	gpio = <&gpio3 RK_PD6 GPIO_ACTIVE_HIGH>;
+};
+
+&vcc5v0_host_en {
+	rockchip,pins = <3 RK_PD6 RK_FUNC_GPIO &pcfg_pull_none>;
+};
board/rockchip/evb_rk3399/MAINTAINERS +2 -0
index 578638a58b..4c889e06a6 100644
@@ -68,6 +68,8 @@ M:	Jagan Teki <[email protected]>
  S:	Maintained
  F:	configs/rock-pi-4-rk3399_defconfig
  F:	arch/arm/dts/rk3399-rock-pi-4-u-boot.dtsi
+F:	configs/rock-pi-4c-rk3399_defconfig
+F:	arch/arm/dts/rk3399-rock-pi-4c-u-boot.dtsi
 
  ROCK-PI-N10
  M:	Jagan Teki <[email protected]>
configs/rock-pi-4c-rk3399_defconfig new file +74 -0
new file mode 100644
index 0000000000..1d34476825
@@ -0,0 +1,74 @@
+CONFIG_ARM=y
+CONFIG_ARCH_ROCKCHIP=y
+CONFIG_SYS_TEXT_BASE=0x00200000
+CONFIG_ENV_OFFSET=0x3F8000
+CONFIG_ROCKCHIP_RK3399=y
+CONFIG_TARGET_EVB_RK3399=y
+CONFIG_NR_DRAM_BANKS=1
+CONFIG_DEBUG_UART_BASE=0xFF1A0000
+CONFIG_DEBUG_UART_CLOCK=24000000
+CONFIG_DEBUG_UART=y
+# CONFIG_ANDROID_BOOT_IMAGE is not set
+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rock-pi-4b.dtb"
+CONFIG_MISC_INIT_R=y
+CONFIG_DISPLAY_BOARDINFO_LATE=y
+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
+CONFIG_SPL_STACK_R=y
+CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN=0x10000
+CONFIG_TPL=y
+CONFIG_CMD_BOOTZ=y
+CONFIG_CMD_GPT=y
+CONFIG_CMD_MMC=y
+CONFIG_CMD_PCI=y
+CONFIG_CMD_USB=y
+# CONFIG_CMD_SETEXPR is not set
+CONFIG_CMD_TIME=y
+CONFIG_SPL_OF_CONTROL=y
+CONFIG_DEFAULT_DEVICE_TREE="rk3399-rock-pi-4b"
+CONFIG_OF_SPL_REMOVE_PROPS="pinctrl-0 pinctrl-names clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents"
+CONFIG_ENV_IS_IN_MMC=y
+CONFIG_SYS_RELOC_GD_ENV_ADDR=y
+CONFIG_ROCKCHIP_GPIO=y
+CONFIG_SYS_I2C_ROCKCHIP=y
+CONFIG_MISC=y
+CONFIG_MMC_DW=y
+CONFIG_MMC_DW_ROCKCHIP=y
+CONFIG_MMC_SDHCI=y
+CONFIG_MMC_SDHCI_ROCKCHIP=y
+CONFIG_DM_ETH=y
+CONFIG_ETH_DESIGNWARE=y
+CONFIG_GMAC_ROCKCHIP=y
+CONFIG_NVME=y
+CONFIG_PCI=y
+CONFIG_PHY_ROCKCHIP_INNO_USB2=y
+CONFIG_PHY_ROCKCHIP_TYPEC=y
+CONFIG_PMIC_RK8XX=y
+CONFIG_REGULATOR_PWM=y
+CONFIG_REGULATOR_RK8XX=y
+CONFIG_PWM_ROCKCHIP=y
+CONFIG_RAM_RK3399_LPDDR4=y
+CONFIG_DM_RESET=y
+CONFIG_BAUDRATE=1500000
+CONFIG_DEBUG_UART_SHIFT=2
+CONFIG_SYSRESET=y
+CONFIG_USB=y
+CONFIG_USB_XHCI_HCD=y
+CONFIG_USB_XHCI_DWC3=y
+CONFIG_USB_EHCI_HCD=y
+CONFIG_USB_EHCI_GENERIC=y
+CONFIG_USB_DWC3=y
+CONFIG_USB_DWC3_GENERIC=y
+CONFIG_USB_KEYBOARD=y
+CONFIG_USB_GADGET=y
+CONFIG_USB_HOST_ETHER=y
+CONFIG_USB_ETHER_ASIX=y
+CONFIG_USB_ETHER_ASIX88179=y
+CONFIG_USB_ETHER_MCS7830=y
+CONFIG_USB_ETHER_RTL8152=y
+CONFIG_USB_ETHER_SMSC95XX=y
+CONFIG_DM_VIDEO=y
+CONFIG_DISPLAY=y
+CONFIG_VIDEO_ROCKCHIP=y
+CONFIG_DISPLAY_ROCKCHIP_HDMI=y
+CONFIG_SPL_TINY_MEMSET=y
+CONFIG_ERRNO_STR=y
Reviewed-by on v1 1/2
#3 lore raw
In reply to Jagan Teki
Quoted 8 lines · Jagan Teki

Rock PI 4 has 3 variants of hardware platforms called RockPI 4A, 4B, and 4C.

- Rock PI 4A has no Wif/BT.
- Rock PI 4B has AP6256 Wifi/BT, PoE.
- Rock PI 4C has AP6256 Wifi/BT, PoE, miniDP, USB Host enable GPIO pin change compared to 4B, 4C

Quoted 7 lines

So move common nodes, properties into dtsi file and include on respective variant dts files.

Use 4B dts into default rock-pi-4 defconfig until we find any solution for dynamic detection of these variants.

Thanks,
- Kever

Quoted 186 lines

---
Note: Linux dts changes on mailing-list
https://lkml.org/lkml/2020/7/20/443
https://lkml.org/lkml/2020/7/20/444

  arch/arm/dts/Makefile                         |  3 +-
  ...99-rock-pi-4.dts => rk3399-rock-pi-4.dtsi} | 26 ------------
  arch/arm/dts/rk3399-rock-pi-4a.dts            | 13 ++++++
  arch/arm/dts/rk3399-rock-pi-4b-u-boot.dtsi    |  6 +++
  arch/arm/dts/rk3399-rock-pi-4b.dts            | 42 +++++++++++++++++++
  configs/rock-pi-4-rk3399_defconfig            |  4 +-
  6 files changed, 65 insertions(+), 29 deletions(-)

rename arch/arm/dts/{rk3399-rock-pi-4.dts => rk3399-rock-pi-4.dtsi} (95%) create mode 100644 arch/arm/dts/rk3399-rock-pi-4a.dts
create mode 100644 arch/arm/dts/rk3399-rock-pi-4b-u-boot.dtsi create mode 100644 arch/arm/dts/rk3399-rock-pi-4b.dts

arch/arm/dts/Makefile +2 -1
index 82e9b18cb8..bcd89af6a5 100644
@@ -136,7 +136,8 @@ dtb-$(CONFIG_ROCKCHIP_RK3399) += \
  	rk3399-puma-haikou.dtb \
  	rk3399-roc-pc.dtb \
  	rk3399-roc-pc-mezzanine.dtb \
-	rk3399-rock-pi-4.dtb \
+	rk3399-rock-pi-4a.dtb \
+	rk3399-rock-pi-4b.dtb \
  	rk3399-rock960.dtb \
  	rk3399-rockpro64.dtb \
  	rk3399pro-rock-pi-n10.dtb
arch/arm/dts/rk3399-rock-pi-4.dtsi renamed from arch/arm/dts/rk3399-rock-pi-4.dts +0 -26
similarity index 95%
rename from arch/arm/dts/rk3399-rock-pi-4.dts
rename to arch/arm/dts/rk3399-rock-pi-4.dtsi
index 3923ec01ef..1c55a4645b 100644
@@ -11,9 +11,6 @@
  #include "rk3399-opp.dtsi"
 
  / {
-	model = "Radxa ROCK Pi 4";
-	compatible = "radxa,rockpi4", "rockchip,rk3399";
-
  	chosen {
  		stdout-path = "serial2:1500000n8";
  	};
@@ -587,17 +584,6 @@
  	pinctrl-names = "default";
  	pinctrl-0 = <&sdio0_bus4 &sdio0_cmd &sdio0_clk>;
  	sd-uhs-sdr104;
-	status = "okay";
-
-	brcmf: wifi@1 {
-		compatible = "brcm,bcm4329-fmac";
-		reg = <1>;
-		interrupt-parent = <&gpio0>;
-		interrupts = <RK_PA3 GPIO_ACTIVE_HIGH>;
-		interrupt-names = "host-wake";
-		pinctrl-names = "default";
-		pinctrl-0 = <&wifi_host_wake_l>;
-	};
  };
 
  &sdmmc {
@@ -666,18 +652,6 @@
  &uart0 {
  	pinctrl-names = "default";
  	pinctrl-0 = <&uart0_xfer &uart0_cts &uart0_rts>;
-	status = "okay";
-
-	bluetooth {
-		compatible = "brcm,bcm43438-bt";
-		clocks = <&rk808 1>;
-		clock-names = "ext_clock";
-		device-wakeup-gpios = <&gpio2 RK_PD3 GPIO_ACTIVE_HIGH>;
-		host-wakeup-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>;
-		shutdown-gpios = <&gpio0 RK_PB1 GPIO_ACTIVE_HIGH>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&bt_host_wake_l &bt_wake_l &bt_enable_h>;
-	};
  };
 
  &uart2 {
arch/arm/dts/rk3399-rock-pi-4a.dts new file +13 -0
new file mode 100644
index 0000000000..d96dd3ebd3
@@ -0,0 +1,13 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+/*
+ * Copyright (c) 2019 Akash Gajjar <[email protected]>
+ * Copyright (c) 2019 Pragnesh Patel <[email protected]>
+ */
+
+/dts-v1/;
+#include "rk3399-rock-pi-4.dtsi"
+
+/ {
+	model = "Radxa ROCK Pi 4A";
+	compatible = "radxa,rockpi4", "rockchip,rk3399";
+};
arch/arm/dts/rk3399-rock-pi-4b-u-boot.dtsi new file +6 -0
new file mode 100644
index 0000000000..85ee5770ad
@@ -0,0 +1,6 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2019 Jagan Teki <[email protected]>
+ */
+
+#include "rk3399-rock-pi-4-u-boot.dtsi"
arch/arm/dts/rk3399-rock-pi-4b.dts new file +42 -0
new file mode 100644
index 0000000000..4ca970acac
@@ -0,0 +1,42 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+/*
+ * Copyright (c) 2019 Akash Gajjar <[email protected]>
+ * Copyright (c) 2019 Pragnesh Patel <[email protected]>
+ */
+
+/dts-v1/;
+#include "rk3399-rock-pi-4.dtsi"
+
+/ {
+	model = "Radxa ROCK Pi 4B";
+	compatible = "radxa,rockpi4", "rockchip,rk3399";
+};
+
+&sdio0 {
+	status = "okay";
+
+	brcmf: wifi@1 {
+		compatible = "brcm,bcm4329-fmac";
+		reg = <1>;
+		interrupt-parent = <&gpio0>;
+		interrupts = <RK_PA3 GPIO_ACTIVE_HIGH>;
+		interrupt-names = "host-wake";
+		pinctrl-names = "default";
+		pinctrl-0 = <&wifi_host_wake_l>;
+	};
+};
+
+&uart0 {
+	status = "okay";
+
+	bluetooth {
+		compatible = "brcm,bcm43438-bt";
+		clocks = <&rk808 1>;
+		clock-names = "ext_clock";
+		device-wakeup-gpios = <&gpio2 RK_PD3 GPIO_ACTIVE_HIGH>;
+		host-wakeup-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>;
+		shutdown-gpios = <&gpio0 RK_PB1 GPIO_ACTIVE_HIGH>;
+		pinctrl-names = "default";
+		pinctrl-0 = <&bt_host_wake_l &bt_wake_l &bt_enable_h>;
+	};
+};
configs/rock-pi-4-rk3399_defconfig +2 -2
index 98f71a50a5..1d34476825 100644
@@ -9,7 +9,7 @@ CONFIG_DEBUG_UART_BASE=0xFF1A0000
  CONFIG_DEBUG_UART_CLOCK=24000000
  CONFIG_DEBUG_UART=y
  # CONFIG_ANDROID_BOOT_IMAGE is not set
-CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rock-pi-4.dtb"
+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rock-pi-4b.dtb"
  CONFIG_MISC_INIT_R=y
  CONFIG_DISPLAY_BOARDINFO_LATE=y
  # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
@@ -24,7 +24,7 @@ CONFIG_CMD_USB=y
  # CONFIG_CMD_SETEXPR is not set
  CONFIG_CMD_TIME=y
  CONFIG_SPL_OF_CONTROL=y
-CONFIG_DEFAULT_DEVICE_TREE="rk3399-rock-pi-4"
+CONFIG_DEFAULT_DEVICE_TREE="rk3399-rock-pi-4b"
  CONFIG_OF_SPL_REMOVE_PROPS="pinctrl-0 pinctrl-names clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents"
  CONFIG_ENV_IS_IN_MMC=y
  CONFIG_SYS_RELOC_GD_ENV_ADDR=y