diff options
author | Andy Adamson <andros@netapp.com> | 2016-09-09 09:22:19 -0400 |
---|---|---|
committer | Anna Schumaker <Anna.Schumaker@Netapp.com> | 2016-09-19 13:08:36 -0400 |
commit | 8e548edb4006c126e4aafba26a80c924e82fd2b4 (patch) | |
tree | 65753297f7a0b51aa6fdce0b697454e9b5dfce10 | |
parent | 8d89bd70bc93914359fca3f7fbe2bde9556bcf76 (diff) |
NFS refactor nfs4_match_clientids
For session trunking, to compare nfs41_exchange_id_res with
exiting nfs_client.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
-rw-r--r-- | fs/nfs/nfs4client.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/nfs/nfs4client.c b/fs/nfs/nfs4client.c index cd3b7cfdde16..b3a5d91a1351 100644 --- a/fs/nfs/nfs4client.c +++ b/fs/nfs/nfs4client.c | |||
@@ -562,15 +562,15 @@ out: | |||
562 | /* | 562 | /* |
563 | * Returns true if the client IDs match | 563 | * Returns true if the client IDs match |
564 | */ | 564 | */ |
565 | static bool nfs4_match_clientids(struct nfs_client *a, struct nfs_client *b) | 565 | static bool nfs4_match_clientids(u64 a, u64 b) |
566 | { | 566 | { |
567 | if (a->cl_clientid != b->cl_clientid) { | 567 | if (a != b) { |
568 | dprintk("NFS: --> %s client ID %llx does not match %llx\n", | 568 | dprintk("NFS: --> %s client ID %llx does not match %llx\n", |
569 | __func__, a->cl_clientid, b->cl_clientid); | 569 | __func__, a, b); |
570 | return false; | 570 | return false; |
571 | } | 571 | } |
572 | dprintk("NFS: --> %s client ID %llx matches %llx\n", | 572 | dprintk("NFS: --> %s client ID %llx matches %llx\n", |
573 | __func__, a->cl_clientid, b->cl_clientid); | 573 | __func__, a, b); |
574 | return true; | 574 | return true; |
575 | } | 575 | } |
576 | 576 | ||
@@ -650,7 +650,7 @@ int nfs41_walk_client_list(struct nfs_client *new, | |||
650 | if (pos->cl_cons_state != NFS_CS_READY) | 650 | if (pos->cl_cons_state != NFS_CS_READY) |
651 | continue; | 651 | continue; |
652 | 652 | ||
653 | if (!nfs4_match_clientids(pos, new)) | 653 | if (!nfs4_match_clientids(pos->cl_clientid, new->cl_clientid)) |
654 | continue; | 654 | continue; |
655 | 655 | ||
656 | /* | 656 | /* |