Skip to contentSkip to conversation

arm64: add initial support for the Rockchip rk3368

PATCH New Heiko Stübner 3 participants 9 messages Jun 25, 2015 – Jun 26, 2015

Subsystems (4)
lore
Share & tools
lore

Heiko Stübner

author maintainer
#0 lore raw

cover arm64: add initial support for the Rockchip rk3368

This adds initial support for the new rk3368 ARM64 soc from Rockchip.

Overall it looks like someone dropped some A53 cores into a rk3288, so it shares a lot of peripherals that only differ in details. Therefore stuff like the mmc, usb, spi, i2c controllers work out of the box. The support for the gmac already made it into the merge window as well as the pinctrl support.

Interestingly, in its core the rk3368 seems trying to be a model student with psci for smp and using scpi for ddr frequency scaling, although I currently do not understand how the mailbox works yet. The display controllers also are only minimally different so I'm hopefully to have working graphics in the near-ish future :-)

As mentioned in the dts patch, this series depends on the dt-binding header for the clock ids, so will need a shared branch once this is ready.

Heiko Stuebner (4):
arm64: add Rockchip architecture entry
arm64: defconfig: enable ARCH_ROCKCHIP
arm64: dts: add Rockchip rk3368 core dtsi and board dts for the r88
board
dt-bindings: document rk3368 R89 board from Rockchip

 Documentation/devicetree/bindings/arm/rockchip.txt |   4 +
 arch/arm64/Kconfig                                 |  10 +
 arch/arm64/boot/dts/Makefile                       |   1 +
 arch/arm64/boot/dts/rockchip/Makefile              |   5 +
 arch/arm64/boot/dts/rockchip/rk3368-r88.dts        | 353 ++++++++
 arch/arm64/boot/dts/rockchip/rk3368.dtsi           | 900 +++++++++++++++++++++
 arch/arm64/configs/defconfig                       |   2 +
 7 files changed, 1275 insertions(+)
 create mode 100644 arch/arm64/boot/dts/rockchip/Makefile
 create mode 100644 arch/arm64/boot/dts/rockchip/rk3368-r88.dts
 create mode 100644 arch/arm64/boot/dts/rockchip/rk3368.dtsi
Signature · 1 line
2.1.4
author maintainer
#1 lore raw

PATCH 1/4 arm64: add Rockchip architecture entry

The rk3368 is Rockchip's first ARM64 soc, build around 8 Cortex-A53 cores.

---
 arch/arm64/Kconfig | 10 ++++++++++
 1 file changed, 10 insertions(+)
arch/arm64/Kconfig +10 -0
index 290ed64..9af528a 100644
@@ -197,6 +197,16 @@ config ARCH_QCOM
 	help
 	  This enables support for the ARMv8 based Qualcomm chipsets.
 
+config ARCH_ROCKCHIP
+	bool "Rockchip Platforms"
+	select ARCH_HAS_RESET_CONTROLLER
+	select ARCH_REQUIRE_GPIOLIB
+	select PINCTRL
+	select PINCTRL_ROCKCHIP
+	help
+	  This enables support for the ARMv8 based Rockchip chipsets,
+	  like the RK3368.
+
 config ARCH_SEATTLE
 	bool "AMD Seattle SoC Family"
 	help
Signature · 1 line
2.1.4
author maintainer
#2 lore raw

PATCH 2/4 arm64: defconfig: enable ARCH_ROCKCHIP

In reply to Heiko Stübner

Enable building Rockchip support in the defconfig.

---
 arch/arm64/configs/defconfig | 2 ++
 1 file changed, 2 insertions(+)
arch/arm64/configs/defconfig +2 -0
index daefbf0..77bc5bc 100644
@@ -34,6 +34,7 @@ CONFIG_MODULE_UNLOAD=y
 CONFIG_ARCH_EXYNOS7=y
 CONFIG_ARCH_FSL_LS2085A=y
 CONFIG_ARCH_MEDIATEK=y
+CONFIG_ARCH_ROCKCHIP=y
 CONFIG_ARCH_SEATTLE=y
 CONFIG_ARCH_TEGRA=y
 CONFIG_ARCH_TEGRA_132_SOC=y
@@ -99,6 +100,7 @@ CONFIG_SERIO_AMBAKMI=y
 CONFIG_LEGACY_PTY_COUNT=16
 CONFIG_SERIAL_8250=y
 CONFIG_SERIAL_8250_CONSOLE=y
+CONFIG_SERIAL_8250_DW=y
 CONFIG_SERIAL_8250_MT6577=y
 CONFIG_SERIAL_AMBA_PL011=y
 CONFIG_SERIAL_AMBA_PL011_CONSOLE=y
Signature · 1 line
2.1.4
author maintainer
#3 lore raw

PATCH 3/4 arm64: dts: add Rockchip rk3368 core dtsi and board dts for the r88 board

In reply to Heiko Stübner

In terms of peripherals the rk3368 is quite similar to the rk3288, which makes it possible to have a lot basic components working in the first go. More to follow once I tracked down all the tiny differences that still exist in some parts.

With these dts files, the R88 board is able to boot from an attached usb device and most likely from its emmc too, if the emmc uses a standard partition table instead of Rockchip's own one - the emmc itself is detected correctly.

---
This of course needs the dt-binding header from clock series, so a shared branch will be needed.

 arch/arm64/boot/dts/Makefile                |   1 +
 arch/arm64/boot/dts/rockchip/Makefile       |   5 +
 arch/arm64/boot/dts/rockchip/rk3368-r88.dts | 353 +++++++++++
 arch/arm64/boot/dts/rockchip/rk3368.dtsi    | 900 ++++++++++++++++++++++++++++
 4 files changed, 1259 insertions(+)
 create mode 100644 arch/arm64/boot/dts/rockchip/Makefile
 create mode 100644 arch/arm64/boot/dts/rockchip/rk3368-r88.dts
 create mode 100644 arch/arm64/boot/dts/rockchip/rk3368.dtsi
arch/arm64/boot/dts/Makefile +1 -0
index ad26a75..6916eec 100644
@@ -6,6 +6,7 @@ dts-dirs += exynos
 dts-dirs += freescale
 dts-dirs += mediatek
 dts-dirs += qcom
+dts-dirs += rockchip
 dts-dirs += sprd
 dts-dirs += xilinx
 
arch/arm64/boot/dts/rockchip/Makefile new file +5 -0
new file mode 100644
index 0000000..601e6a2
@@ -0,0 +1,5 @@
+dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3368-r88.dtb
+
+always		:= $(dtb-y)
+subdir-y	:= $(dts-dirs)
+clean-files	:= *.dtb
arch/arm64/boot/dts/rockchip/rk3368-r88.dts new file +353 -0

353 lines not on this page · raw message

arch/arm64/boot/dts/rockchip/rk3368.dtsi new file +900 -0

900 lines not on this page · raw message

Signature · 1 line
2.1.4
reviewer
#4 lore raw

PATCH 3/4 arm64: dts: add Rockchip rk3368 core dtsi and board dts for the r88 board

[...]

arch/arm64/boot/dts/rockchip/rk3368-r88.dts line 56

Quoted 3 lines
arch/arm64/boot/dts/rockchip/rk3368-r88.dts new file +3 -0
+       memory {
+               reg = <0x0 0x0 0x0 0x40000000>;
+       };

This needs device_type = "memory", no?

I guess the bootloader is overriding this anyway?

Otherwise this looked fine to me.

Thanks,
Mark.

author maintainer
#5 lore raw

PATCH 4/4 dt-bindings: document rk3368 R89 board from Rockchip

In reply to Heiko Stübner

The initial board containing the rk3368 ARM64 soc.

---
This should probably be simply in one branch with the Netxeon board seen in the diff above, to prevent unncessary merge conflicts?

 Documentation/devicetree/bindings/arm/rockchip.txt | 4 ++++
 1 file changed, 4 insertions(+)
Documentation/devicetree/bindings/arm/rockchip.txt +4 -0
index b30bed1..c4119e0 100644
@@ -30,3 +30,7 @@ Rockchip platforms device tree bindings
 - Netxeon R89 board:
     Required root node properties:
       - compatible = "netxeon,r89", "rockchip,rk3288";
+
+- Rockchip R88 board:
+    Required root node properties:
+      - compatible = "rockchip,r88", "rockchip,rk3368";
Signature · 1 line
2.1.4
#6 lore raw

cover arm64: add initial support for the Rockchip rk3368

In reply to Heiko Stübner

Hi, Heiko

Could I test the code on rk3368 STB such as EKB368, CSA90? Is there some documents about it?

Thanks

bamvor

Quoted 38 lines · Heiko St?bner

This adds initial support for the new rk3368 ARM64 soc from Rockchip.

Overall it looks like someone dropped some A53 cores into a rk3288, so it shares a lot of peripherals that only differ in details. Therefore stuff like the mmc, usb, spi, i2c controllers work out of the box. The support for the gmac already made it into the merge window as well as the pinctrl support.

Interestingly, in its core the rk3368 seems trying to be a model student with psci for smp and using scpi for ddr frequency scaling, although I currently do not understand how the mailbox works yet. The display controllers also are only minimally different so I'm hopefully to have working graphics in the near-ish future :-)

As mentioned in the dts patch, this series depends on the dt-binding header for the clock ids, so will need a shared branch once this is ready.

Heiko Stuebner (4):
arm64: add Rockchip architecture entry
arm64: defconfig: enable ARCH_ROCKCHIP
arm64: dts: add Rockchip rk3368 core dtsi and board dts for the r88
board
dt-bindings: document rk3368 R89 board from Rockchip

  Documentation/devicetree/bindings/arm/rockchip.txt |   4 +
  arch/arm64/Kconfig                                 |  10 +
  arch/arm64/boot/dts/Makefile                       |   1 +
  arch/arm64/boot/dts/rockchip/Makefile              |   5 +
  arch/arm64/boot/dts/rockchip/rk3368-r88.dts        | 353 ++++++++
  arch/arm64/boot/dts/rockchip/rk3368.dtsi           | 900 +++++++++++++++++++++
  arch/arm64/configs/defconfig                       |   2 +
  7 files changed, 1275 insertions(+)

create mode 100644 arch/arm64/boot/dts/rockchip/Makefile create mode 100644 arch/arm64/boot/dts/rockchip/rk3368-r88.dts create mode 100644 arch/arm64/boot/dts/rockchip/rk3368.dtsi

author maintainer
#7 lore raw

cover arm64: add initial support for the Rockchip rk3368

Hi Bamvor,

Am Freitag, 26. Juni 2015, 12:35:58 schrieb Bamvor Jian Zhang:

Quoted 2 lines

Could I test the code on rk3368 STB such as EKB368, CSA90? Is there some documents about it?

General information on flashing generic Rockchip devices can be found on [0]. That didn't change for the rk3368 it seems - although a device _might_ be locked down to prevent reflashing it seems.

You will of course also need a serial console on the device for the time being, so finding the test-points and soldering is probably required.

Heiko

[0] http://linux-rockchip.info

Quoted 40 lines · Heiko St?bner
Quoted 39 lines

This adds initial support for the new rk3368 ARM64 soc from Rockchip.

Overall it looks like someone dropped some A53 cores into a rk3288, so it shares a lot of peripherals that only differ in details. Therefore stuff like the mmc, usb, spi, i2c controllers work out of the box. The support for the gmac already made it into the merge window as well as the pinctrl support.

Interestingly, in its core the rk3368 seems trying to be a model student with psci for smp and using scpi for ddr frequency scaling, although I currently do not understand how the mailbox works yet. The display controllers also are only minimally different so I'm hopefully to have working graphics in the near-ish future :-)

As mentioned in the dts patch, this series depends on the dt-binding header for the clock ids, so will need a shared branch once this is ready.

Heiko Stuebner (4):
arm64: add Rockchip architecture entry
arm64: defconfig: enable ARCH_ROCKCHIP
arm64: dts: add Rockchip rk3368 core dtsi and board dts for the r88

board

dt-bindings: document rk3368 R89 board from Rockchip

  Documentation/devicetree/bindings/arm/rockchip.txt |   4 +
  arch/arm64/Kconfig                                 |  10 +
  arch/arm64/boot/dts/Makefile                       |   1 +
  arch/arm64/boot/dts/rockchip/Makefile              |   5 +
  arch/arm64/boot/dts/rockchip/rk3368-r88.dts        | 353 ++++++++
  arch/arm64/boot/dts/rockchip/rk3368.dtsi           | 900
  +++++++++++++++++++++ arch/arm64/configs/defconfig                     
   |   2 +
  7 files changed, 1275 insertions(+)

create mode 100644 arch/arm64/boot/dts/rockchip/Makefile create mode 100644 arch/arm64/boot/dts/rockchip/rk3368-r88.dts create mode 100644 arch/arm64/boot/dts/rockchip/rk3368.dtsi

#8 lore raw

cover arm64: add initial support for the Rockchip rk3368

Hi, Heiko

2015-06-26 15:17 GMT+08:00 Heiko St?bner <[email protected]>:

Quoted 6 lines

Hi Bamvor,

Am Freitag, 26. Juni 2015, 12:35:58 schrieb Bamvor Jian Zhang:

Quoted 2 lines

Could I test the code on rk3368 STB such as EKB368, CSA90? Is there some documents about it?

Quoted 6 lines

General information on flashing generic Rockchip devices can be found on [0]. That didn't change for the rk3368 it seems - although a device _might_ be locked down to prevent reflashing it seems.

You will of course also need a serial console on the device for the time being, so finding the test-points and soldering is probably required.

Thanks, I will try it.

bamvor

Quoted 49 lines

Heiko

[0] http://linux-rockchip.info

Quoted 40 lines · Heiko St?bner
Quoted 39 lines

This adds initial support for the new rk3368 ARM64 soc from Rockchip.

Overall it looks like someone dropped some A53 cores into a rk3288, so it shares a lot of peripherals that only differ in details. Therefore stuff like the mmc, usb, spi, i2c controllers work out of the box. The support for the gmac already made it into the merge window as well as the pinctrl support.

Interestingly, in its core the rk3368 seems trying to be a model student with psci for smp and using scpi for ddr frequency scaling, although I currently do not understand how the mailbox works yet. The display controllers also are only minimally different so I'm hopefully to have working graphics in the near-ish future :-)

As mentioned in the dts patch, this series depends on the dt-binding header for the clock ids, so will need a shared branch once this is ready.

Heiko Stuebner (4):
arm64: add Rockchip architecture entry
arm64: defconfig: enable ARCH_ROCKCHIP
arm64: dts: add Rockchip rk3368 core dtsi and board dts for the r88

board

dt-bindings: document rk3368 R89 board from Rockchip

  Documentation/devicetree/bindings/arm/rockchip.txt |   4 +
  arch/arm64/Kconfig                                 |  10 +
  arch/arm64/boot/dts/Makefile                       |   1 +
  arch/arm64/boot/dts/rockchip/Makefile              |   5 +
  arch/arm64/boot/dts/rockchip/rk3368-r88.dts        | 353 ++++++++
  arch/arm64/boot/dts/rockchip/rk3368.dtsi           | 900
  +++++++++++++++++++++ arch/arm64/configs/defconfig
   |   2 +
  7 files changed, 1275 insertions(+)

create mode 100644 arch/arm64/boot/dts/rockchip/Makefile create mode 100644 arch/arm64/boot/dts/rockchip/rk3368-r88.dts create mode 100644 arch/arm64/boot/dts/rockchip/rk3368.dtsi