git: 3ed48eb085f7 - main - riscv: build allwinner DTBs

From: Mitchell Horne <mhorne_at_FreeBSD.org>
Date: Mon, 20 Oct 2025 23:42:16 UTC
The branch main has been updated by mhorne:

URL: https://cgit.FreeBSD.org/src/commit/?id=3ed48eb085f7c4ae5c019ee882e694b432d43911

commit 3ed48eb085f7c4ae5c019ee882e694b432d43911
Author:     Mitchell Horne <mhorne@FreeBSD.org>
AuthorDate: 2025-10-20 14:25:08 +0000
Commit:     Mitchell Horne <mhorne@FreeBSD.org>
CommitDate: 2025-10-20 23:37:13 +0000

    riscv: build allwinner DTBs
    
    These are known to work if loaded manually by loader(8) (for the Nezha
    board at least). If nothing else, it is useful to provide a DTB closely
    tied to the kernel version.
    
    MFC after:      3 days
    Sponsored by:   The FreeBSD Foundation
    Differential Revision:  https://reviews.freebsd.org/D53118
---
 sys/modules/dtb/allwinner/Makefile | 7 ++++++-
 sys/riscv/conf/std.allwinner       | 3 +++
 2 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/sys/modules/dtb/allwinner/Makefile b/sys/modules/dtb/allwinner/Makefile
index 242ee5d974ad..2666e786a9df 100644
--- a/sys/modules/dtb/allwinner/Makefile
+++ b/sys/modules/dtb/allwinner/Makefile
@@ -65,7 +65,12 @@ DTSO=	sun50i-a64-mmc0-disable.dtso \
 	sun50i-a64-timer.dtso \
 	sun50i-h5-opp.dtso \
 	sun50i-h5-nanopi-neo2-opp.dtso
-
+.elif ${MACHINE_CPUARCH} == "riscv"
+DTS=	\
+	allwinner/sun20i-d1-dongshan-nezha-stu.dts \
+	allwinner/sun20i-d1-lichee-rv.dts \
+	allwinner/sun20i-d1-mangopi-mq-pro.dts \
+	allwinner/sun20i-d1-nezha.dts
 .endif
 
 .include <bsd.dtb.mk>
diff --git a/sys/riscv/conf/std.allwinner b/sys/riscv/conf/std.allwinner
index 34fe195b01ba..ecd789f39963 100644
--- a/sys/riscv/conf/std.allwinner
+++ b/sys/riscv/conf/std.allwinner
@@ -17,4 +17,7 @@ device		awg		# Allwinner EMAC Gigabit Ethernet
 
 device		musb		# Mentor Graphics USB OTG controller
 
+# DTBs
+makeoptions	MODULES_EXTRA+="dtb/allwinner"
+
 files		"../allwinner/files.allwinner"