cache: get rid of the global lock

Add a table of vnode locks and use them along with bucketlocks to provide
concurrent modification support. The approach taken is to preserve the
current behaviour of the namecache and just lock all relevant parts before
any changes are made.

Lookups still require the relevant bucket to be locked.

Discussed with:		kib
Tested by:	pho
This commit is contained in:
mjg 2016-09-23 04:45:11 +00:00
parent c3a5f7973c
commit 75d7d065e6
2 changed files with 742 additions and 239 deletions

View File

@ -625,7 +625,7 @@ static struct witness_order_list_entry order_lists[] = {
/*
* VFS namecache
*/
{ "ncglobal", &lock_class_rw },
{ "ncvn", &lock_class_mtx_sleep },
{ "ncbuc", &lock_class_rw },
{ "vnode interlock", &lock_class_mtx_sleep },
{ "ncneg", &lock_class_mtx_sleep },

File diff suppressed because it is too large Load Diff