From: Chuck Lever <chuck.lever@oracle.com>
To: Jeff Layton <jlayton@kernel.org>, Chuck Lever <cel@kernel.org>,
NeilBrown <neil@brown.name>,
Olga Kornievskaia <okorniev@redhat.com>,
Dai Ngo <dai.ngo@oracle.com>, Tom Talpey <tom@talpey.com>
Cc: linux-nfs@vger.kernel.org, rtm@csail.mit.edu
Subject: Re: [PATCH v1] NFSD: Define actions for the new time_deleg FATTR4 attributes
Date: Mon, 29 Sep 2025 12:37:31 -0400 [thread overview]
Message-ID: <55b3a52e-3ff3-4547-bbbb-61731132baf8@oracle.com> (raw)
In-Reply-To: <728efd15288cfc84b19f4798a725b909757b3fe9.camel@kernel.org>
On 9/29/25 6:39 AM, Jeff Layton wrote:
>> Do clients query SUPPORTED_ATTRS and look for these two bits to
>> know whether to expect attribute delegation?
>>
> The Linux client does:
>
> static bool nfs4_server_delegtime_capable(struct nfs4_server_caps_res *res)
> {
> u32 share_access_want = res->open_caps.oa_share_access_want[0];
> u32 attr_bitmask = res->attr_bitmask[2];
>
> return (share_access_want & NFS4_SHARE_WANT_DELEG_TIMESTAMPS) &&
> ((attr_bitmask & FATTR4_WORD2_NFS42_TIME_DELEG_MASK) ==
> FATTR4_WORD2_NFS42_TIME_DELEG_MASK);
> }
>
>
> ...so I guess we can't report them as unsupported. They do still need
> to be supported for SETATTR. Still, we should just mask them off if
> someone tries to query for them.
There appears to be a bit of a gray area here. RFC 8881 Section 18.7.3
states:
> The server MUST return a value for each attribute that the client
> requests if the attribute is supported by the server for the target
> file system. If the server does not support a particular attribute on
> the target file system, then it MUST NOT return the attribute value
> and MUST NOT set the attribute bit in the result bitmap. The server
> MUST return an error if it supports an attribute on the target but
> cannot obtain its value. In that case, no attribute values will be
> returned.
RFC 9754 Section 5 states:
> These new attributes are invalid to be used with GETATTR, VERIFY, and
> NVERIFY, and they can only be used with CB_GETATTR and SETATTR by a
> client holding an appropriate delegation.
This text does not prescribe a specific server response if it should be
presented with a GETATTR operation (or a READDIR, one assumes) that
queries delegated time stamps.
Perhaps, rather than clearing the result bitmask, NFS4ERR_INVAL is the
mandated server response.
--
Chuck Lever
next prev parent reply other threads:[~2025-09-29 16:37 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-10 15:29 [PATCH v1] NFSD: Define actions for the new time_deleg FATTR4 attributes Chuck Lever
2025-09-10 15:47 ` Chuck Lever
2025-09-10 17:01 ` Jeff Layton
2025-09-29 13:16 ` Chuck Lever
2025-09-29 13:29 ` Jeff Layton
2025-09-29 13:32 ` Chuck Lever
2025-09-29 13:39 ` Jeff Layton
2025-09-29 16:37 ` Chuck Lever [this message]
2025-09-29 16:43 ` Jeff Layton
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=55b3a52e-3ff3-4547-bbbb-61731132baf8@oracle.com \
--to=chuck.lever@oracle.com \
--cc=cel@kernel.org \
--cc=dai.ngo@oracle.com \
--cc=jlayton@kernel.org \
--cc=linux-nfs@vger.kernel.org \
--cc=neil@brown.name \
--cc=okorniev@redhat.com \
--cc=rtm@csail.mit.edu \
--cc=tom@talpey.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).