Date: Thu, 18 Jan 2024 22:43:45 GMT From: John Baldwin <jhb@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: git: 49413aa308fc - stable/14 - ctladm: Only autoload cfiscsi.ko for iSCSI-specific commands Message-ID: <202401182243.40IMhj7i025120@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=49413aa308fce38b25d70af33b156191b1d6753c commit 49413aa308fce38b25d70af33b156191b1d6753c Author: John Baldwin <jhb@FreeBSD.org> AuthorDate: 2023-12-27 18:11:19 +0000 Commit: John Baldwin <jhb@FreeBSD.org> CommitDate: 2024-01-18 22:41:43 +0000 ctladm: Only autoload cfiscsi.ko for iSCSI-specific commands Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D42935 (cherry picked from commit 0f3210b3a7fac2cb247986dae4d68040222cdb33) --- usr.sbin/ctladm/ctladm.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/usr.sbin/ctladm/ctladm.c b/usr.sbin/ctladm/ctladm.c index 3ccf93d5e94e..e99610373ff0 100644 --- a/usr.sbin/ctladm/ctladm.c +++ b/usr.sbin/ctladm/ctladm.c @@ -4145,10 +4145,16 @@ main(int argc, char **argv) goto bailout; } #ifdef WANT_ISCSI - else { + switch (command) { + case CTLADM_CMD_ISLIST: + case CTLADM_CMD_ISLOGOUT: + case CTLADM_CMD_ISTERMINATE: if (modfind("cfiscsi") == -1 && kldload("cfiscsi") == -1) warn("couldn't load cfiscsi"); + break; + default: + break; } #endif } else if ((command != CTLADM_CMD_HELP)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202401182243.40IMhj7i025120>