name cache: remove changes entry to negative
instead of calling name_cache_entry_unlink(), nfs41_name_cache_remove() calls name_cache_entry_update() with NULL for fh and info to make it a negative entry, then name_cache_unlink_children_recursive() to remove any children Signed-off-by: Casey Bodley <cbodley@umich.edu>
This commit is contained in:
parent
6ee8bba79e
commit
61ddf671fa
1 changed files with 6 additions and 2 deletions
|
|
@ -994,8 +994,12 @@ int nfs41_name_cache_remove(
|
|||
if (status == ERROR_FILE_NOT_FOUND)
|
||||
goto out_unlock;
|
||||
|
||||
if (target->attributes)
|
||||
target->attributes->numlinks--;
|
||||
name_cache_unlink(cache, target);
|
||||
|
||||
/* make this a negative entry and unlink children */
|
||||
name_cache_entry_update(cache, target, NULL, NULL);
|
||||
name_cache_unlink_children_recursive(cache, target);
|
||||
|
||||
out_unlock:
|
||||
ReleaseSRWLockExclusive(&cache->lock);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue