Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 30 May 2024 10:43:34 GMT
From:      Emmanuel Vadot <manu@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: 9433da0bcbf9 - main - sysutils/nanopi-r5s: Add new port
Message-ID:  <202405301043.44UAhY6D042877@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by manu:

URL: https://cgit.FreeBSD.org/ports/commit/?id=9433da0bcbf9194ef84bc42a2b6b1ee1401fc758

commit 9433da0bcbf9194ef84bc42a2b6b1ee1401fc758
Author:     Emmanuel Vadot <manu@FreeBSD.org>
AuthorDate: 2024-05-30 09:47:26 +0000
Commit:     Emmanuel Vadot <manu@FreeBSD.org>
CommitDate: 2024-05-30 10:43:14 +0000

    sysutils/nanopi-r5s: Add new port
    
    Add a new u-boot port for FriendlyElelc Nanopi R5S
    
    Sponsored by:   Beckhoff Automation GmbH & Co. KG
---
 sysutils/Makefile                    |  1 +
 sysutils/u-boot-master/Makefile      | 11 +++++++++++
 sysutils/u-boot-nanopi-r5s/Makefile  |  7 +++++++
 sysutils/u-boot-nanopi-r5s/pkg-descr |  6 ++++++
 4 files changed, 25 insertions(+)

diff --git a/sysutils/Makefile b/sysutils/Makefile
index 40b4a10c3c40..8746c3e88b3f 100644
--- a/sysutils/Makefile
+++ b/sysutils/Makefile
@@ -1512,6 +1512,7 @@
     SUBDIR += u-boot-nanopi-neo2
     SUBDIR += u-boot-nanopi-r2s
     SUBDIR += u-boot-nanopi-r4s
+    SUBDIR += u-boot-nanopi-r5s
     SUBDIR += u-boot-olimex-a20-som-evb
     SUBDIR += u-boot-olinuxino-lime
     SUBDIR += u-boot-olinuxino-lime2
diff --git a/sysutils/u-boot-master/Makefile b/sysutils/u-boot-master/Makefile
index 52718c4ee8b0..bf867cdca70d 100644
--- a/sysutils/u-boot-master/Makefile
+++ b/sysutils/u-boot-master/Makefile
@@ -104,6 +104,10 @@ UBOOT_ARCH_RK3328=	aarch64
 UBOOT_PLIST_RK3399=	idbloader.img u-boot.itb
 UBOOT_ARCH_RK3399=	aarch64
 
+# Override for RK356X family
+UBOOT_PLIST_RK356X=	idbloader.img u-boot.itb
+UBOOT_ARCH_RK356X=	aarch64
+
 # Override for ARMADA38X family
 UBOOT_PLIST_ARMADA38X=	u-boot-with-spl.kwb
 UBOOT_METADATA_ARMADA38X_FILES=		${UBOOT_PLIST_ARMADA38X}
@@ -181,6 +185,13 @@ BUILD_DEPENDS+=	${LOCALBASE}/share/atf-rk3399/bl31.elf:sysutils/atf-rk3399 \
 MAKE_ENV+=	BL31=${LOCALBASE}/share/atf-rk3399/bl31.elf
 .endif
 
+.if defined(FAMILY) && ${FAMILY} == rk356X
+BUILD_DEPENDS+=	${LOCALBASE}/share/rkbin/rk35/rk3566_ddr_1056MHz_v1.21.bin:sysutils/rkbin \
+		${PYTHON_PKGNAMEPREFIX}pyelftools>0:devel/py-pyelftools@${PY_FLAVOR}
+MAKE_ENV+=	BL31=${LOCALBASE}/share/rkbin/rk35/rk3568_bl31_v1.44.elf \
+		ROCKCHIP_TPL=${LOCALBASE}/share/rkbin/rk35/rk3566_ddr_1056MHz_v1.21.bin
+.endif
+
 # Each u-boot family has different files to include, bring them in.
 .for i in ${UBOOT_PLIST}
 PLIST_FILES+=	${UBOOT_DIR}/${i}
diff --git a/sysutils/u-boot-nanopi-r5s/Makefile b/sysutils/u-boot-nanopi-r5s/Makefile
new file mode 100644
index 000000000000..439f88fc5c37
--- /dev/null
+++ b/sysutils/u-boot-nanopi-r5s/Makefile
@@ -0,0 +1,7 @@
+MASTERDIR=	${.CURDIR}/../u-boot-master
+
+MODEL=		nanopi-r5s
+BOARD_CONFIG=	nanopi-r5s-rk3568_defconfig
+FAMILY=		rk356X
+
+.include "${MASTERDIR}/Makefile"
diff --git a/sysutils/u-boot-nanopi-r5s/pkg-descr b/sysutils/u-boot-nanopi-r5s/pkg-descr
new file mode 100644
index 000000000000..b51949596521
--- /dev/null
+++ b/sysutils/u-boot-nanopi-r5s/pkg-descr
@@ -0,0 +1,6 @@
+U-Boot loader and related files for the FriendlyARM NanoPi-R5S
+
+To install this bootloader on an sdcard just do:
+
+dd if=/usr/local/share/u-boot/u-boot-nanopi-r5s/idbloader.img of=/path/to/sdcarddevice seek=64 bs=512 conv=sync
+dd if=/usr/local/share/u-boot/u-boot-nanopi-r5s/u-boot.itb of=/path/to/sdcarddevice seek=16384 bs=512 conv=sync



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