Date: Fri, 30 Oct 2020 08:06:56 +0000 (UTC) From: Hans Petter Selasky <hselasky@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r367158 - stable/11/sys/fs/cuse Message-ID: <202010300806.09U86uN1038995@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: hselasky Date: Fri Oct 30 08:06:56 2020 New Revision: 367158 URL: https://svnweb.freebsd.org/changeset/base/367158 Log: MFC r366961: Fix for loading cuse.ko via rc.d . Make sure we declare the cuse(3) module by name and not only by the version information, so that "kldstat -q -m cuse" works. Found by: Goran Mekic <meka@tilda.center> Sponsored by: Mellanox Technologies // NVIDIA Networking Modified: stable/11/sys/fs/cuse/cuse.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/fs/cuse/cuse.c ============================================================================== --- stable/11/sys/fs/cuse/cuse.c Fri Oct 30 08:05:47 2020 (r367157) +++ stable/11/sys/fs/cuse/cuse.c Fri Oct 30 08:06:56 2020 (r367158) @@ -66,6 +66,24 @@ #include <fs/cuse/cuse_defs.h> #include <fs/cuse/cuse_ioctl.h> +static int +cuse_modevent(module_t mod, int type, void *data) +{ + switch (type) { + case MOD_LOAD: + case MOD_UNLOAD: + return (0); + default: + return (EOPNOTSUPP); + } +} + +static moduledata_t cuse_mod = { + .name = "cuse", + .evhand = &cuse_modevent, +}; + +DECLARE_MODULE(cuse, cuse_mod, SI_SUB_DEVFS, SI_ORDER_FIRST); MODULE_VERSION(cuse, 1); /*
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202010300806.09U86uN1038995>