[Bug 172942] [smbfs] Unmounting a smb mount when the server became unavailable causes kernel panic
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Fri Oct 16 12:34:06 UTC 2015
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=172942
Rick Macklem <rmacklem at FreeBSD.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|freebsd-fs at FreeBSD.org |rmacklem at FreeBSD.org
--- Comment #3 from Rick Macklem <rmacklem at FreeBSD.org> ---
I believe there is a race caused by smb_iod_destroy() where it
calls sbm_iod_request() to shutdown the connection/iod thread.
smb_iod_request() does an msleep(..PDROP..), which can return
as soon as smb_iod_main() does the wakeup(). After returning
from the msleep(), it returns to smb_iod_destroy(), which then
destroys the mutexes and frees the iod structure.
Unfortunately, smb_iod_main() is not done with the mutexes when
it calls wakeup().
I believe this patch fixes the problem by moving the code that
destroys the mutexs and frees the iod structure to the end of
the smb_iod thread.
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the freebsd-fs
mailing list