On Thu, Jul 14, 2016 at 08:51:45PM +0000, Michael van Elst wrote: > dholland-t...@netbsd.org (David Holland) writes: > > >Is there any reason lfs is using a global (rather than per-volume) > >lock? ad@ seems to have introduced it but as usual there's little in > >the way of reasoning or explanation. > > After changing lfs to use the new locking primitives it was utterly > broken. So don't try to interpret much into the global lock. It's > just a slightly more local version of the big kernel lock. >
Hmm, some users of KERNEL_LOCK still remain. I think using both may be causing problems. KERNEL_LOCK forces lfs_lock, but not all KERNEL_LOCK users check for lfs_lock. The one that does (lfs_cluster_aiodone), does it within KERNEL_LOCK, not outside.