Browse Source

visionfive2: opensbi: Fix OpenSBI QA error and recipe clean up
This happens due to the mistake in a6128e3a62af3754279cfac01a0467256866a35b, the bbappend file is renamed to the wrong version for VisionFive2.
After clean up, this package recipe follows a new convention:
opensbi_1.2.bb --> Forked from Poky latest recipe (vanilla)
opensbi_%.bbappend: --> Machine-specific source and its build configurations

Hence, any future change to the OpenSBI recipe should be done on opensbi_%.bbappend.

Signed-off-by: weiheng.cheng <weiheng.cheng@starfivetech.com>

weiheng.cheng 5 months ago
parent
commit
d979d1a081

+ 41 - 0
recipes-bsp/opensbi/opensbi_%.bbappend

@@ -0,0 +1,41 @@
+FORK:starfive-dubhe = "starfive-tech"
+BRANCH:starfive-dubhe = "starfive-v1.2-dubhe"
+SRCREV:starfive-dubhe = "a10e0837f215fb4ed25f195f2c511a41deb9c324"
+
+FORK:starfive-visionfive2 = "starfive-tech"
+BRANCH:starfive-visionfive2 = "master"
+SRCREV:starfive-visionfive2 = "c6a092cd80112529cb2e92e180767ff5341b22a3"
+
+FORK:starfive-jh8100 = "starfive-tech"
+BRANCH:starfive-jh8100 = "fpga-starfive-v1.2-jh8100"
+SRCREV:starfive-jh8100 = "06c3d05b7f5f1e0aa24141e4de487313b620cea9"
+
+SRC_URI:starfive-dubhe = "\
+	git://github.com/${FORK}/opensbi.git;protocol=https;branch=${BRANCH} \
+	"
+
+SRC_URI:starfive-visionfive2 = "\
+	git://github.com/${FORK}/opensbi.git;protocol=https;branch=${BRANCH} \
+	file://visionfive2-uboot-fit-image.its \
+	"
+
+SRC_URI:starfive-jh8100 = "\
+        git://git@192.168.110.45/${FORK}/opensbi.git;protocol=ssh;branch=${BRANCH} \
+        "
+
+SRC_URI:remove:nezha = "\
+        file://0001-lib-utils-fdt-Require-match-data-to-be-const.patch \
+        file://0002-lib-utils-timer-Add-a-separate-compatible-for-the-D1.patch \
+        "
+
+EXTRA_OEMAKE:starfive-dubhe = "PLATFORM=${RISCV_SBI_PLAT} I=${D} FW_PIC=n CLANG_TARGET= FW_OPTIONS=0 FW_TEXT_START=0x80100000 PLATFORM_DEFCONFIG=starfive_defconfig"
+EXTRA_OEMAKE:starfive-visionfive2 = "PLATFORM=${RISCV_SBI_PLAT} I=${D} FW_PIC=n CLANG_TARGET= FW_TEXT_START=0x40000000"
+EXTRA_OEMAKE:starfive-jh8100 = "PLATFORM=${RISCV_SBI_PLAT} I=${D} FW_PIC=n CLANG_TARGET= FW_OPTIONS=0 FW_TEXT_START=0x40000000 PLATFORM_DEFCONFIG=starfive_defconfig"
+
+DEPENDS:starfive-visionfive2 += "u-boot-tools-native dtc-native"
+
+do_deploy:append:starfive-visionfive2() {
+	install -m 0644 ${WORKDIR}/visionfive2-uboot-fit-image.its ${DEPLOYDIR}/visionfive2-uboot-fit-image.its
+	cd ${DEPLOYDIR}
+	mkimage -f visionfive2-uboot-fit-image.its -A riscv -O u-boot -T firmware visionfive2_fw_payload.img
+}

+ 0 - 18
recipes-bsp/opensbi/opensbi_1.0.bbappend

@@ -1,18 +0,0 @@
-FORK:starfive-visionfive2 = "starfive-tech"
-BRANCH:starfive-visionfive2 = "master"
-SRCREV:starfive-visionfive2 = "c6a092cd80112529cb2e92e180767ff5341b22a3"
-
-SRC_URI:starfive-visionfive2 = "\
-	git://github.com/${FORK}/opensbi.git;protocol=https;branch=${BRANCH} \
-	file://visionfive2-uboot-fit-image.its \
-	"
-
-EXTRA_OEMAKE:starfive-visionfive2 += "PLATFORM=${RISCV_SBI_PLAT} I=${D} FW_PIC=n CLANG_TARGET= FW_TEXT_START=0x40000000"
-
-DEPENDS:starfive-visionfive2 += "u-boot-tools-native dtc-native"
-
-do_deploy:append:starfive-visionfive2() {
-	install -m 0644 ${WORKDIR}/visionfive2-uboot-fit-image.its ${DEPLOYDIR}/visionfive2-uboot-fit-image.its
-	cd ${DEPLOYDIR}
-	mkimage -f visionfive2-uboot-fit-image.its -A riscv -O u-boot -T firmware visionfive2_fw_payload.img
-}

+ 3 - 23
recipes-bsp/opensbi/opensbi_1.2.bb

@@ -8,32 +8,12 @@ require opensbi-payloads.inc
 
 inherit autotools-brokensep deploy
 
-FORK:starfive-dubhe = "starfive-tech"
-BRANCH:starfive-dubhe = "starfive-v1.2-dubhe"
-SRCREV:starfive-dubhe = "a10e0837f215fb4ed25f195f2c511a41deb9c324"
-
-FORK:starfive-jh8100 = "starfive-tech"
-BRANCH:starfive-jh8100 = "fpga-starfive-v1.2-jh8100"
-SRCREV:starfive-jh8100 = "06c3d05b7f5f1e0aa24141e4de487313b620cea9"
-
-SRC_URI:starfive-dubhe = "\
-	git://github.com/${FORK}/opensbi.git;protocol=https;branch=${BRANCH} \
-	"
-
-SRC_URI:starfive-jh8100 = "\
-	git://git@192.168.110.45/${FORK}/opensbi.git;protocol=ssh;branch=${BRANCH} \
-	"
-
-SRC_URI:remove:nezha = "\
-	file://0001-lib-utils-fdt-Require-match-data-to-be-const.patch \
-	file://0002-lib-utils-timer-Add-a-separate-compatible-for-the-D1.patch \
-	"
+SRCREV = "6b5188ca14e59ce7bf71afe4e7d3d557c3d31bf8"
+SRC_URI = "git://github.com/riscv/opensbi.git;branch=master;protocol=https"
 
 S = "${WORKDIR}/git"
 
-EXTRA_OEMAKE:starfive-dubhe = "PLATFORM=${RISCV_SBI_PLAT} I=${D} FW_PIC=n CLANG_TARGET= FW_OPTIONS=0 FW_TEXT_START=0x80100000 PLATFORM_DEFCONFIG=starfive_defconfig"
-EXTRA_OEMAKE:starfive-jh8100 = "PLATFORM=${RISCV_SBI_PLAT} I=${D} FW_PIC=n CLANG_TARGET= FW_OPTIONS=0 FW_TEXT_START=0x40000000 PLATFORM_DEFCONFIG=starfive_defconfig"
-
+EXTRA_OEMAKE += "PLATFORM=${RISCV_SBI_PLAT} I=${D} FW_PIC=n CLANG_TARGET= "
 # If RISCV_SBI_PAYLOAD is set then include it as a payload
 EXTRA_OEMAKE:append = " ${@riscv_get_extra_oemake_image(d)}"
 EXTRA_OEMAKE:append = " ${@riscv_get_extra_oemake_fdt(d)}"