git: kernel - Fix umount -f related panic

Matthew Dillon dillon at
Tue Dec 19 19:20:38 PST 2023

commit 44a20c7f35de6ac28d870a45c6c2d8d79c34a054
Author: Matthew Dillon <dillon at>
Date:   Tue Dec 19 19:14:23 2023 -0800

    kernel - Fix umount -f related panic
    * Adjust umount -f (forced unmount) logic to kill processes which
      still hold references to the mount in question, due to being chrooted
      or jailed in the mount, their current directory being on the mount,
      or having any open file via the mount.
      To be frank, it is hard to find a nice way to rip a mount out from under
      processes as their behavior upon suddenly having file descriptors go bad
      is completely non-deterministic.  A forced unmount is not supposed to be
      kind to the system.  The best solution is to kill the processes.
    * Fixes panics related to regular use of umount -f if the operation
      happens to race active operations by processes on the mount.
    Reported-by: marino

Summary of changes:
 sys/kern/vfs_syscalls.c | 90 +++++++++++++++++++++++++++++++++++++++++++++----
 1 file changed, 83 insertions(+), 7 deletions(-)

DragonFly BSD source repository

More information about the Commits mailing list