kernel - Fix mount refs interactions and umount races
authorMatthew Dillon <dillon@apollo.backplane.com>
Fri, 23 Mar 2012 04:37:25 +0000 (21:37 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Fri, 23 Mar 2012 04:37:25 +0000 (21:37 -0700)
commit6fa06591a194a4b88811a5049f88fefcc060fee5
treedd80a588d125a7f277418c348c05d05b36a90408
parent3d102df7db4f442f9921757788d791d3ec0ebca0
kernel - Fix mount refs interactions and umount races

* It is possible for a umount to race other operations on active mount
  point, causing one or the other to deadlock.

* vfs_busy()/vfs_unbusy() now incr/decr mp->mnt_refs.

* cache_findmount() now increments mp->mnt_refs, and add a new API
  function cache_dropmount() which decrements it.
sys/kern/vfs_cache.c
sys/kern/vfs_mount.c
sys/kern/vfs_nlookup.c
sys/kern/vfs_syscalls.c
sys/sys/namecache.h