Skip to contentSkip to conversation

nfs: fix the fetch of FATTR4_OPEN_ARGUMENTS

PATCH In review Jeff Layton 4 participants 6 messages Aug 15, 2024 – Aug 21, 2024

Subsystems (2)
lore
Share & tools
lore

Jeff Layton

author maintainer
#0 lore raw

PATCH 1/1 nfs: fix the fetch of FATTR4_OPEN_ARGUMENTS

The client doesn't properly request FATTR4_OPEN_ARGUMENTS in the initial SERVER_CAPS getattr. Add FATTR4_WORD2_OPEN_ARGUMENTS to the initial request.

Fixes 707f13b3d081 (NFSv4: Add support for the FATTR4_OPEN_ARGUMENTS attribute)
---
 fs/nfs/nfs4proc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/nfs/nfs4proc.c +1 -1
index 8883016c551c..39ad7780986c 100644
@@ -3931,7 +3931,7 @@ static int _nfs4_server_capabilities(struct nfs_server *server, struct nfs_fh *f
 		     FATTR4_WORD0_CASE_INSENSITIVE |
 		     FATTR4_WORD0_CASE_PRESERVING;
 	if (minorversion)
-		bitmask[2] = FATTR4_WORD2_SUPPATTR_EXCLCREAT;
+		bitmask[2] = FATTR4_WORD2_SUPPATTR_EXCLCREAT | FATTR4_WORD2_OPEN_ARGUMENTS;
 
 	status = nfs4_call_sync(server->client, server, &msg, &args.seq_args, &res.seq_res, 0);
 	if (status == 0) {
Signature · 1 line
2.46.0
author maintainer
#1 lore raw
Quoted 15 lines · Jeff Layton

The client doesn't properly request FATTR4_OPEN_ARGUMENTS in the initial SERVER_CAPS getattr. Add FATTR4_WORD2_OPEN_ARGUMENTS to the initial request.

Fixes 707f13b3d081 (NFSv4: Add support for the FATTR4_OPEN_ARGUMENTS attribute)
---
 fs/nfs/nfs4proc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/nfs/nfs4proc.c +0 -0
index 8883016c551c..39ad7780986c 100644

fs/nfs/nfs4proc.c static int _nfs4_server_capabilities(struct nfs_server *server, struct nfs_fh *f · line 3937

Quoted 8 lines
fs/nfs/nfs4proc.c +1 -1
@@ -3931,7 +3931,7 @@ static int _nfs4_server_capabilities(struct nfs_server *server, struct nfs_fh *f
 		     FATTR4_WORD0_CASE_INSENSITIVE |
 		     FATTR4_WORD0_CASE_PRESERVING;
 	if (minorversion)
-		bitmask[2] = FATTR4_WORD2_SUPPATTR_EXCLCREAT;
+		bitmask[2] = FATTR4_WORD2_SUPPATTR_EXCLCREAT | FATTR4_WORD2_OPEN_ARGUMENTS;
 
 	status = nfs4_call_sync(server->client, server, &msg, &args.seq_args, &res.seq_res, 0);
 	if (status == 0) {

Ping? It would be nice to have this fixed before v6.11 ships.

Signature · 1 line
Jeff Layton <[email protected]>
maintainer
#2 lore raw
Quoted 23 lines · Jeff Layton
Quoted 21 lines · Jeff Layton

The client doesn't properly request FATTR4_OPEN_ARGUMENTS in the initial SERVER_CAPS getattr. Add FATTR4_WORD2_OPEN_ARGUMENTS to the initial request.

Fixes 707f13b3d081 (NFSv4: Add support for the FATTR4_OPEN_ARGUMENTS attribute)
---
 fs/nfs/nfs4proc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/nfs/nfs4proc.c +1 -1
index 8883016c551c..39ad7780986c 100644
@@ -3931,7 +3931,7 @@ static int _nfs4_server_capabilities(struct nfs_server *server, struct nfs_fh *f
                   FATTR4_WORD0_CASE_INSENSITIVE |
                   FATTR4_WORD0_CASE_PRESERVING;
      if (minorversion)
-             bitmask[2] = FATTR4_WORD2_SUPPATTR_EXCLCREAT;
+             bitmask[2] = FATTR4_WORD2_SUPPATTR_EXCLCREAT | FATTR4_WORD2_OPEN_ARGUMENTS;
 
Quoted 4 lines

fs/nfs/nfs4proc.c static int _nfs4_server_capabilities(struct nfs_server *server, struct nfs_fh *f · line 3937

Quoted 2 lines
fs/nfs/nfs4proc.c +0 -0
      status = nfs4_call_sync(server->client, server, &msg, &args.seq_args, &res.seq_res, 0);
      if (status == 0) {

Ping? It would be nice to have this fixed before v6.11 ships.

This and your other patch both look good to me. I'll try to get out a bugfixes pull request by the end of the week!

Anna

Quoted 2 lines

--
Jeff Layton <[email protected]>

Reviewed-by on v1 1/1
#3 lore raw
In reply to Jeff Layton
Quoted 6 lines · Jeff Layton

The client doesn't properly request FATTR4_OPEN_ARGUMENTS in the initial SERVER_CAPS getattr. Add FATTR4_WORD2_OPEN_ARGUMENTS to the initial request.

Fixes 707f13b3d081 (NFSv4: Add support for the FATTR4_OPEN_ARGUMENTS attribute)

Clearly correct, save for slight style mismatch.

Ben

author maintainer
#4 lore raw
Quoted 11 lines · Benjamin Coddington
Quoted 8 lines · Jeff Layton

The client doesn't properly request FATTR4_OPEN_ARGUMENTS in the initial
SERVER_CAPS getattr. Add FATTR4_WORD2_OPEN_ARGUMENTS to the initial request.

Fixes 707f13b3d081 (NFSv4: Add support for the

FATTR4_OPEN_ARGUMENTS attribute)

Quoted 6 lines

Clearly correct, save for slight style mismatch.

Ben

Thanks. I noticed that after sending it. No objection if you want to fix that up before merging.

Signature · 1 line
Jeff Layton <[email protected]>
#5 lore raw
Quoted 15 lines · Jeff Layton
Quoted 14 lines · Benjamin Coddington
Quoted 9 lines · Jeff Layton

The client doesn't properly request FATTR4_OPEN_ARGUMENTS in the initial
SERVER_CAPS getattr. Add FATTR4_WORD2_OPEN_ARGUMENTS to the initial
request.

Fixes 707f13b3d081 (NFSv4: Add support for the

FATTR4_OPEN_ARGUMENTS attribute)

Clearly correct, save for slight style mismatch.

Quoted 7 lines
Quoted 4 lines

Ben

Thanks. I noticed that after sending it. No objection if you want to fix that up before merging.

Ack to this too.

Signature · 3 lines
Trond Myklebust
Linux NFS client maintainer, Hammerspace
[email protected]