git: d00aff627828 - main - provide easy way to disable kld_list loading

Warner Losh imp at FreeBSD.org
Wed May 5 21:21:17 UTC 2021


The branch main has been updated by imp:

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

commit d00aff627828ef69d7333537e3a81b47bfa1a8e8
Author:     Warner Losh <imp at FreeBSD.org>
AuthorDate: 2020-10-25 06:22:43 +0000
Commit:     Warner Losh <imp at FreeBSD.org>
CommitDate: 2021-05-05 21:19:41 +0000

    provide easy way to disable kld_list loading
    
    set kld_disbale=y or any value in the boot loader and that will
    disable loading of the kld_list.
    
    Differential Revision: https://reviews.freebsd.org/D26939
---
 libexec/rc/rc.d/kld | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libexec/rc/rc.d/kld b/libexec/rc/rc.d/kld
index d3829efe824a..e9a8e6d37a08 100755
--- a/libexec/rc/rc.d/kld
+++ b/libexec/rc/rc.d/kld
@@ -41,6 +41,7 @@ stop_cmd=':'
 kld_start()
 {
 	[ -n "$kld_list" ] || return
+	[ -z "$(kenv -q kld_disable 2>/dev/null)" ] || return
 
 	local _kld
 


More information about the dev-commits-src-main mailing list