[Bug 248050] Keeps handle to loaded kernel module twice?

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Thu Jul 23 15:09:47 UTC 2020


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=248050

Mark Johnston <markj at FreeBSD.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |markj at FreeBSD.org
             Status|New                         |Closed
         Resolution|---                         |Not A Bug

--- Comment #2 from Mark Johnston <markj at FreeBSD.org> ---
This is by design, though the behaviour is admittedly not intuitive.  When you
kldload dtrace, dtrace.ko gets a reference; loading dtraceall.ko adds a second
reference to dtrace.ko.

The first attempt to unload dtrace releases the initial reference, but
dtraceall.ko's reference ensures that dtrace.ko remains loaded.  The second
attempt to unload fails because dtraceall.ko still depends on dtrace.ko. 
Unloading dtraceall.ko should cause dtrace.ko to be unloaded automatically in
that case.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-bugs mailing list