Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 24 Feb 2025 21:17:43 GMT
From:      Mitchell Horne <mhorne@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: 1ebf5e656c9f - main - sysutils/opensbi: update to v1.6
Message-ID:  <202502242117.51OLHhAJ021579@gitrepo.freebsd.org>

index | next in thread | raw e-mail

The branch main has been updated by mhorne:

URL: https://cgit.FreeBSD.org/ports/commit/?id=1ebf5e656c9fcc68e6f62685e0e97e4228a4267a

commit 1ebf5e656c9fcc68e6f62685e0e97e4228a4267a
Author:     Mitchell Horne <mhorne@FreeBSD.org>
AuthorDate: 2024-07-08 14:34:35 +0000
Commit:     Mitchell Horne <mhorne@FreeBSD.org>
CommitDate: 2025-02-24 21:17:28 +0000

    sysutils/opensbi: update to v1.6
    
    Remove the port platform OPTIONS in favor of the 'generic' platform
    only. This has been the only one we've shipped with for a few versions
    now.
    
    This cleans up the Makefile, but more to the point, there is some kind
    of build regression with the new version that doing the make and install
    in a single step seems to fix.
    
    Bump dependent u-boot ports.
    
    Sponsored by:   The FreeBSD Foundation
---
 sysutils/opensbi/Makefile                          | 33 +++++-----------------
 sysutils/opensbi/distinfo                          |  6 ++--
 sysutils/opensbi/files/patch-Makefile              | 20 -------------
 .../files/patch-platform_generic_sifive_fu540.c    |  5 ++--
 sysutils/opensbi/pkg-plist                         |  8 +++---
 sysutils/u-boot-sifive-fu540/Makefile              |  2 ++
 sysutils/u-boot-sifive-fu740/Makefile              |  2 ++
 sysutils/u-boot-starfive-visionfive2/Makefile      |  2 ++
 8 files changed, 23 insertions(+), 55 deletions(-)

diff --git a/sysutils/opensbi/Makefile b/sysutils/opensbi/Makefile
index 745ca761c7de..703e9218ed9f 100644
--- a/sysutils/opensbi/Makefile
+++ b/sysutils/opensbi/Makefile
@@ -1,6 +1,6 @@
 PORTNAME=	opensbi
 DISTVERSIONPREFIX=v
-DISTVERSION=	1.4
+DISTVERSION=	1.6
 CATEGORIES=	sysutils
 
 MAINTAINER=	mhorne@FreeBSD.org
@@ -18,15 +18,10 @@ SHEBANG_FILES=	scripts/Kconfiglib/*.py
 USE_GITHUB=	yes
 GH_ACCOUNT=	riscv-software-src
 
-MAKE_ARGS=	LLVM=1 I=${STAGEDIR}${PREFIX} V=1 FW_PAYLOAD=n
+MAKE_ARGS=	LLVM=1 I=${STAGEDIR}${PREFIX} V=1 \
+		FW_PAYLOAD=n FW_TEXT_START=0x80000000 \
+		OPENSBI_VERSION_GIT= PLATFORM=generic
 
-OPTIONS_GROUP=		PLATFORMS
-OPTIONS_GROUP_PLATFORMS=GENERIC
-OPTIONS_SUB=		yes
-OPTIONS_DEFAULT=	GENERIC
-
-GENERIC_DESC=		Support for generic platform
-GENERIC_PLATFORM=	generic
 GENERIC_STRIP_ARGS=	-K tohost -K fromhost
 
 INSTALL_TARGET=		install
@@ -35,22 +30,8 @@ PLIST_SUB+=		RISCV_ABI=${PLATFORM_RISCV_ABI}
 
 PLATFORM_RISCV_ABI=	lp64
 
-do-install: # only need install_firmwares target
-
-.for platform in ${OPTIONS_GROUP_PLATFORMS}
-
-post-build-${platform}-on:
-	${MAKE_CMD} -C ${WRKSRC} ${MAKE_ARGS} PLATFORM=${${platform}_PLATFORM}
-
-do-install-${platform}-on:
-	${MKDIR} ${STAGEDIR}${PREFIX}
-	${MAKE_CMD} -C ${WRKSRC} PLATFORM=${${platform}_PLATFORM} ${MAKE_ARGS} \
-		I=${STAGEDIR}${PREFIX} V=1 install_firmwares
-
-post-install-${platform}-on:
-	${STRIP_CMD} ${${platform}_STRIP_ARGS} \
-	    ${STAGEDIR}${DATADIR}/${PLATFORM_RISCV_ABI}/${${platform}_PLATFORM}/firmware/fw_*.elf
-
-.endfor # OPTIONS_GROUP_PLATFORMS
+post-install:
+	${STRIP_CMD} ${GENERIC_STRIP_ARGS} \
+	    ${STAGEDIR}${DATADIR}/${PLATFORM_RISCV_ABI}/generic/firmware/fw_*.elf
 
 .include <bsd.port.mk>
diff --git a/sysutils/opensbi/distinfo b/sysutils/opensbi/distinfo
index fbed4ec056d0..27de00840a02 100644
--- a/sysutils/opensbi/distinfo
+++ b/sysutils/opensbi/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1704470709
-SHA256 (riscv-software-src-opensbi-v1.4_GH0.tar.gz) = 319b62a4186fbce9b81a0c5f0ec9f003a10c808397a72138bc9745d9b87b1eb1
-SIZE (riscv-software-src-opensbi-v1.4_GH0.tar.gz) = 409903
+TIMESTAMP = 1735930463
+SHA256 (riscv-software-src-opensbi-v1.6_GH0.tar.gz) = d11702103f177a2914e94eec57ce5ed820296d874f6b6525c4482e55d71a3667
+SIZE (riscv-software-src-opensbi-v1.6_GH0.tar.gz) = 476631
diff --git a/sysutils/opensbi/files/patch-Makefile b/sysutils/opensbi/files/patch-Makefile
deleted file mode 100644
index e98a465c25da..000000000000
--- a/sysutils/opensbi/files/patch-Makefile
+++ /dev/null
@@ -1,20 +0,0 @@
---- Makefile.orig	2023-07-19 06:21:59 UTC
-+++ Makefile
-@@ -337,7 +337,7 @@ endif
- else
- CFLAGS		+=	-O2
- endif
--CFLAGS		+=	-fno-omit-frame-pointer -fno-optimize-sibling-calls -mstrict-align
-+CFLAGS		+=	-fno-omit-frame-pointer -fno-optimize-sibling-calls
- # enable -m(no-)save-restore option by CC_SUPPORT_SAVE_RESTORE
- ifeq ($(CC_SUPPORT_SAVE_RESTORE),y)
- CFLAGS		+=	-mno-save-restore
-@@ -355,7 +355,7 @@ ASFLAGS		=	-g -Wall -nostdlib
- CPPFLAGS	+=	$(firmware-cppflags-y)
- 
- ASFLAGS		=	-g -Wall -nostdlib
--ASFLAGS		+=	-fno-omit-frame-pointer -fno-optimize-sibling-calls -mstrict-align
-+ASFLAGS		+=	-fno-omit-frame-pointer -fno-optimize-sibling-calls
- # enable -m(no-)save-restore option by CC_SUPPORT_SAVE_RESTORE
- ifeq ($(CC_SUPPORT_SAVE_RESTORE),y)
- ASFLAGS		+=	-mno-save-restore
diff --git a/sysutils/opensbi/files/patch-platform_generic_sifive_fu540.c b/sysutils/opensbi/files/patch-platform_generic_sifive_fu540.c
index fa402a00203b..9f776d796e1b 100644
--- a/sysutils/opensbi/files/patch-platform_generic_sifive_fu540.c
+++ b/sysutils/opensbi/files/patch-platform_generic_sifive_fu540.c
@@ -1,12 +1,13 @@
 --- platform/generic/sifive/fu540.c.orig	2022-06-26 14:27:30 UTC
 +++ platform/generic/sifive/fu540.c
-@@ -11,6 +11,15 @@
+@@ -11,6 +11,16 @@
  #include <sbi_utils/fdt/fdt_helper.h>
  #include <sbi_utils/fdt/fdt_fixup.h>
  
 +extern int need_pmp_war;
 +
-+static int sifive_fu540_early_init(bool cold_boot, const struct fdt_match *match)
++static int sifive_fu540_early_init(bool cold_boot, const void *fdt,
++				    const struct fdt_match *match)
 +{
 +	need_pmp_war = true;
 +
diff --git a/sysutils/opensbi/pkg-plist b/sysutils/opensbi/pkg-plist
index 444198483dc1..cc5e3f421a5b 100644
--- a/sysutils/opensbi/pkg-plist
+++ b/sysutils/opensbi/pkg-plist
@@ -1,4 +1,4 @@
-%%GENERIC%%%%DATADIR%%/%%RISCV_ABI%%/generic/firmware/fw_dynamic.bin
-%%GENERIC%%%%DATADIR%%/%%RISCV_ABI%%/generic/firmware/fw_dynamic.elf
-%%GENERIC%%%%DATADIR%%/%%RISCV_ABI%%/generic/firmware/fw_jump.bin
-%%GENERIC%%%%DATADIR%%/%%RISCV_ABI%%/generic/firmware/fw_jump.elf
+%%DATADIR%%/%%RISCV_ABI%%/generic/firmware/fw_dynamic.bin
+%%DATADIR%%/%%RISCV_ABI%%/generic/firmware/fw_dynamic.elf
+%%DATADIR%%/%%RISCV_ABI%%/generic/firmware/fw_jump.bin
+%%DATADIR%%/%%RISCV_ABI%%/generic/firmware/fw_jump.elf
diff --git a/sysutils/u-boot-sifive-fu540/Makefile b/sysutils/u-boot-sifive-fu540/Makefile
index 5f79e53b93d8..51643c092390 100644
--- a/sysutils/u-boot-sifive-fu540/Makefile
+++ b/sysutils/u-boot-sifive-fu540/Makefile
@@ -1,5 +1,7 @@
 MASTERDIR=	${.CURDIR}/../u-boot-master
 
+U_BOOT_SLAVE_PORTREVISION_2024.07=1
+
 MODEL=		sifive-fu540
 BOARD_CONFIG=	sifive_unleashed_defconfig
 FAMILY=		sifive
diff --git a/sysutils/u-boot-sifive-fu740/Makefile b/sysutils/u-boot-sifive-fu740/Makefile
index 3902e50d6394..98d38e935010 100644
--- a/sysutils/u-boot-sifive-fu740/Makefile
+++ b/sysutils/u-boot-sifive-fu740/Makefile
@@ -1,5 +1,7 @@
 MASTERDIR=	${.CURDIR}/../u-boot-master
 
+U_BOOT_SLAVE_PORTREVISION_2024.07=1
+
 MODEL=		sifive-fu740
 BOARD_CONFIG=	sifive_unmatched_defconfig
 FAMILY=		sifive
diff --git a/sysutils/u-boot-starfive-visionfive2/Makefile b/sysutils/u-boot-starfive-visionfive2/Makefile
index 101a17f18a02..391d3b2321e6 100644
--- a/sysutils/u-boot-starfive-visionfive2/Makefile
+++ b/sysutils/u-boot-starfive-visionfive2/Makefile
@@ -1,5 +1,7 @@
 MASTERDIR=	${.CURDIR}/../u-boot-master
 
+U_BOOT_SLAVE_PORTREVISION_2024.07=1
+
 MODEL=		starfive-visionfive2
 BOARD_CONFIG=	starfive_visionfive2_defconfig
 FAMILY=		starfive


home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202502242117.51OLHhAJ021579>