name cache: bug fix for delegations
when open_update_cache() calls open_delegation_return() to return its delegation, it doesn't update its local variable 'delegation_type' to reflect the new delegation->type. this causes the next call to nfs41_name_cache_insert() to continue failing Signed-off-by: Casey Bodley <cbodley@citi.umich.edu>
This commit is contained in:
parent
39e90a7299
commit
909947f07a
1 changed files with 2 additions and 3 deletions
|
|
@ -340,8 +340,6 @@ static void open_update_cache(
|
||||||
IN nfs41_getattr_res *file_attrs)
|
IN nfs41_getattr_res *file_attrs)
|
||||||
{
|
{
|
||||||
struct nfs41_name_cache *cache = session_name_cache(session);
|
struct nfs41_name_cache *cache = session_name_cache(session);
|
||||||
enum open_delegation_type4 delegation_type =
|
|
||||||
already_delegated ? OPEN_DELEGATE_NONE : delegation->type;
|
|
||||||
uint32_t status;
|
uint32_t status;
|
||||||
|
|
||||||
/* update the attributes of the parent directory */
|
/* update the attributes of the parent directory */
|
||||||
|
|
@ -355,7 +353,8 @@ static void open_update_cache(
|
||||||
retry_cache_insert:
|
retry_cache_insert:
|
||||||
AcquireSRWLockShared(&file->path->lock);
|
AcquireSRWLockShared(&file->path->lock);
|
||||||
status = nfs41_name_cache_insert(cache, file->path->path, &file->name,
|
status = nfs41_name_cache_insert(cache, file->path->path, &file->name,
|
||||||
&file->fh, file_attrs->info, changeinfo, delegation_type);
|
&file->fh, file_attrs->info, changeinfo,
|
||||||
|
already_delegated ? OPEN_DELEGATE_NONE : delegation->type);
|
||||||
ReleaseSRWLockShared(&file->path->lock);
|
ReleaseSRWLockShared(&file->path->lock);
|
||||||
|
|
||||||
if (status == ERROR_TOO_MANY_OPEN_FILES) {
|
if (status == ERROR_TOO_MANY_OPEN_FILES) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue