mirror of
https://github.com/torvalds/linux.git
synced 2026-05-30 10:04:04 +02:00
NFS: rewrite nfs_delegations_present in terms of nr_active_delegations
Renewal only cares for active delegations and not revoked ones. Replace the list empty check with reading the active delegation counter to implement this. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Anna Schumaker <anna.schumaker@oracle.com>
This commit is contained in:
parent
20151c1136
commit
2d80e59f29
|
|
@ -1453,7 +1453,7 @@ int nfs_delegations_present(struct nfs_client *clp)
|
|||
|
||||
rcu_read_lock();
|
||||
list_for_each_entry_rcu(server, &clp->cl_superblocks, client_link)
|
||||
if (!list_empty(&server->delegations)) {
|
||||
if (atomic_long_read(&server->nr_active_delegations) > 0) {
|
||||
ret = 1;
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user