See https://lists.freebsd.org/archives/freebsd-current/2025-November/009500.html for background. To reproduce, set debug.link_elf_leak_locals=0 debug.link_elf_obj_leak_locals=0 then # kldload mfi_linux.ko link_elf_obj: symbol linux_device_register_handler undefined linker_load_file: /boot/kernel/mfi_linux.ko - unsupported file type kldload: an error occurred while loading module mfi_linux.ko. Please check dmesg(8) for more details. The dependent module's Makefile should have an EXPORT_SYMS= line that lists all of the symbols that should be intentionally exported. Another option (but not preferred) is to just set EXPORT_SYMS=YES, unless we explicitly want all symbols exported.
Also mrsas_linux.ko # kldload mrsas_linux.ko link_elf_obj: symbol linux_device_register_handler undefined linker_load_file: /boot/kernel/mrsas_linux.ko - unsupported file type kldload: an error occurred while loading module mrsas_linux.ko. Please check dmesg(8) for more details.
linux/Makefile and linux_common/Makefile already have EXPORT_SYMS lists, so adding to the existing list makes sense. Unsure if additional symbols beyond linux_device_register_handler are required, but will start with that one.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=3e2093de47251de5e6e61c08d2955251137afd01 commit 3e2093de47251de5e6e61c08d2955251137afd01 Author: Ed Maste <emaste@FreeBSD.org> AuthorDate: 2025-11-28 21:25:26 +0000 Commit: Ed Maste <emaste@FreeBSD.org> CommitDate: 2025-12-29 16:39:28 +0000 linux: Add required symbol to EXPORT_SYMS list PR: 291270 sys/modules/linux/Makefile | 1 + sys/modules/linux_common/Makefile | 1 + 2 files changed, 2 insertions(+)
A commit in branch stable/15 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=4c318cb3320d9aedd17a2e3c07ff5c69225a29eb commit 4c318cb3320d9aedd17a2e3c07ff5c69225a29eb Author: Ed Maste <emaste@FreeBSD.org> AuthorDate: 2025-11-28 21:25:26 +0000 Commit: Ed Maste <emaste@FreeBSD.org> CommitDate: 2026-01-05 16:15:53 +0000 linux: Add required symbol to EXPORT_SYMS list PR: 291270 (cherry picked from commit 3e2093de47251de5e6e61c08d2955251137afd01) sys/modules/linux/Makefile | 1 + sys/modules/linux_common/Makefile | 1 + 2 files changed, 2 insertions(+)
A commit in branch stable/14 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=408cd2fff86176513c69e880d7515af11f980cb7 commit 408cd2fff86176513c69e880d7515af11f980cb7 Author: Ed Maste <emaste@FreeBSD.org> AuthorDate: 2025-11-28 21:25:26 +0000 Commit: Ed Maste <emaste@FreeBSD.org> CommitDate: 2026-01-05 16:25:27 +0000 linux: Add required symbol to EXPORT_SYMS list PR: 291270 (cherry picked from commit 3e2093de47251de5e6e61c08d2955251137afd01) (cherry picked from commit 4c318cb3320d9aedd17a2e3c07ff5c69225a29eb) sys/modules/linux/Makefile | 1 + sys/modules/linux_common/Makefile | 1 + 2 files changed, 2 insertions(+)
^Triage: assign to committer. Is there any reason to leave this Problem Report open now?