Skip to contentSkip to conversation

riscv: dts: Add hifive-unleashed-a00 dts from Linux

PATCH Superseded Jagan Teki 2 participants 3 messages Nov 9, 2019 – Nov 11, 2019

Subsystems (2)

v3 of 4 Superseded Latest is v4 →

lore
Share & tools
lore

Jagan Teki

author
#0 lore raw

PATCH v3 1/2 riscv: dts: Add hifive-unleashed-a00 dts from Linux

Sync the hifive-unleashed-a00 dts from Linux with
below commit details:

commit <2993c9b04e616df0848b655d7202a707a70fc876> ("riscv: dts: HiFive
Unleashed: add default chosen/stdout-path")

Idea is to periodically sync the dts from Linux instead of tweaking internal changes one after another, so better not add any intermediate changes in between. This would help to maintain the dts files easy and meaningful since we are reusing device tree files from Linux.

---
Changes for v3:
- none

 arch/riscv/dts/Makefile                 |   1 +
 arch/riscv/dts/fu540-c000.dtsi          | 251 ++++++++++++++++++++++++
 arch/riscv/dts/hifive-unleashed-a00.dts |  96 +++++++++
 3 files changed, 348 insertions(+)
 create mode 100644 arch/riscv/dts/fu540-c000.dtsi
 create mode 100644 arch/riscv/dts/hifive-unleashed-a00.dts
arch/riscv/dts/Makefile +1 -0
index f9cd606a9a..4f30e6936f 100644
@@ -1,6 +1,7 @@
 # SPDX-License-Identifier: GPL-2.0+
 
 dtb-$(CONFIG_TARGET_AX25_AE350) += ae350_32.dtb ae350_64.dtb
+dtb-$(CONFIG_TARGET_SIFIVE_FU540) += hifive-unleashed-a00.dtb
 
 targets += $(dtb-y)
 
arch/riscv/dts/fu540-c000.dtsi new file +251 -0

251 lines not on this page · raw message

arch/riscv/dts/hifive-unleashed-a00.dts new file +96 -0

96 lines not on this page · raw message

Signature · 1 line
2.18.0.321.gffc6fa0e3
author
#1 lore raw

PATCH v3 2/2 sifive: fu540: Enable OF_SEPARATE

Use dts support from U-Boot via OF_SEPARATE instead of depending from opensbi.

This would help to make the necessary changes in drivers and device trees in U-Boot tree itself. This feature would also be helpful to not pass dtb during opensbi builds.

---
Changes for v3:
- fixed typo changes.

 configs/sifive_fu540_defconfig | 3 ++-
 doc/board/sifive/fu540.rst     | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)
configs/sifive_fu540_defconfig +2 -1
index 48865e5f11..979d0a0418 100644
@@ -6,6 +6,7 @@ CONFIG_RISCV_SMODE=y
 CONFIG_DISTRO_DEFAULTS=y
 CONFIG_FIT=y
 CONFIG_MISC_INIT_R=y
+CONFIG_DEFAULT_DEVICE_TREE="hifive-unleashed-a00"
 CONFIG_DISPLAY_CPUINFO=y
 CONFIG_DISPLAY_BOARDINFO=y
-CONFIG_OF_PRIOR_STAGE=y
+CONFIG_OF_SEPARATE=y
doc/board/sifive/fu540.rst +1 -1
index 7807f5b2c1..91b94ee06f 100644
@@ -58,7 +58,7 @@ firmware. We need to compile OpenSBI with below command:
 
 .. code-block:: none
 
-    make PLATFORM=sifive/fu540 FW_PAYLOAD_PATH=<path to u-boot.bin> FW_PAYLOAD_FDT_PATH=<path to hifive-unleashed-a00.dtb from Linux>
+    make PLATFORM=sifive/fu540 FW_PAYLOAD_PATH=<path to u-boot-dtb.bin>
 
 (Note: Prefer hifive-unleashed-a00.dtb from Linux-5.3 or higher)
 (Note: Linux-5.2 is also fine but it does not have ethernet DT node)
Signature · 1 line
2.18.0.321.gffc6fa0e3
#2 lore raw

PATCH v3 2/2 sifive: fu540: Enable OF_SEPARATE

doc/board/sifive/fu540.rst firmware. We need to compile OpenSBI with below command: · line 64

Quoted 13 lines · Jagan Teki
doc/board/sifive/fu540.rst +1 -1
index 7807f5b2c1..91b94ee06f 100644
@@ -58,7 +58,7 @@ firmware. We need to compile OpenSBI with below command:
 
 .. code-block:: none
 
-    make PLATFORM=sifive/fu540 FW_PAYLOAD_PATH=<path to u-boot.bin> FW_PAYLOAD_FDT_PATH=<path to hifive-unleashed-a00.dtb from Linux>
+    make PLATFORM=sifive/fu540 FW_PAYLOAD_PATH=<path to u-boot-dtb.bin>
 
 (Note: Prefer hifive-unleashed-a00.dtb from Linux-5.3 or higher)
 (Note: Linux-5.2 is also fine but it does not have ethernet DT node)

Are these notes now obsolete?

Andreas.

Signature · 3 lines
Andreas Schwab, SUSE Labs, schwab at suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE  1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."