From: "bfields@fieldses.org" <bfields@fieldses.org>
To: Ondrej Valousek <ondrej.valousek.xm@renesas.com>
Cc: Trond Myklebust <trondmy@hammerspace.com>,
"linux-nfs@vger.kernel.org" <linux-nfs@vger.kernel.org>,
"anna.schumaker@netapp.com" <anna.schumaker@netapp.com>,
"trondmy@kernel.org" <trondmy@kernel.org>
Subject: Re: [PATCH 0/8] Support btime and other NFSv4 specific attributes
Date: Thu, 6 Jan 2022 09:28:12 -0500 [thread overview]
Message-ID: <20220106142812.GC7105@fieldses.org> (raw)
In-Reply-To: <DU2PR10MB50969D4D096DB99EEC6D1C45E14C9@DU2PR10MB5096.EURPRD10.PROD.OUTLOOK.COM>
On Thu, Jan 06, 2022 at 02:19:22PM +0000, Ondrej Valousek wrote:
> > You also need to update the value of NFSD4_SUPPORTED_ATTRS_WORD1 to reflect the new support for FATTR4_WORD1_TIME_CREATE.
>
> Yes, I realized that one shortly after I sent the mail.
> Just going to try this patch:
Thanks!
Don't we want to vary support depending on the filesystem, though? Is
there a way to query that?
--b.
>
> [ondrejv@skynet19 /opt/kernel/linux-git/fs/nfsd]$ git diff
> diff --git a/fs/nfsd/nfs4xdr.c b/fs/nfsd/nfs4xdr.c
> index 5a93a5db4fb0..be47e1dd6da5 100644
> --- a/fs/nfsd/nfs4xdr.c
> +++ b/fs/nfsd/nfs4xdr.c
> @@ -3265,6 +3265,14 @@ nfsd4_encode_fattr(struct xdr_stream *xdr, struct svc_fh *fhp,
> p = xdr_encode_hyper(p, (s64)stat.mtime.tv_sec);
> *p++ = cpu_to_be32(stat.mtime.tv_nsec);
> }
> + /* support for btime here */
> + if (bmval1 & FATTR4_WORD1_TIME_CREATE) {
> + p = xdr_reserve_space(xdr, 12);
> + if (!p)
> + goto out_resource;
> + p = xdr_encode_hyper(p, (s64)stat.btime.tv_sec);
> + *p++ = cpu_to_be32(stat.btime.tv_nsec);
> + }
> if (bmval1 & FATTR4_WORD1_MOUNTED_ON_FILEID) {
> struct kstat parent_stat;
> u64 ino = stat.ino;
> diff --git a/fs/nfsd/nfsd.h b/fs/nfsd/nfsd.h
> index 498e5a489826..5ef056ce7591 100644
> --- a/fs/nfsd/nfsd.h
> +++ b/fs/nfsd/nfsd.h
> @@ -364,7 +364,7 @@ void nfsd_lockd_shutdown(void);
> | FATTR4_WORD1_OWNER | FATTR4_WORD1_OWNER_GROUP | FATTR4_WORD1_RAWDEV \
> | FATTR4_WORD1_SPACE_AVAIL | FATTR4_WORD1_SPACE_FREE | FATTR4_WORD1_SPACE_TOTAL \
> | FATTR4_WORD1_SPACE_USED | FATTR4_WORD1_TIME_ACCESS | FATTR4_WORD1_TIME_ACCESS_SET \
> - | FATTR4_WORD1_TIME_DELTA | FATTR4_WORD1_TIME_METADATA \
> + | FATTR4_WORD1_TIME_DELTA | FATTR4_WORD1_TIME_METADATA | FATTR4_WORD1_TIME_CREATE \
> | FATTR4_WORD1_TIME_MODIFY | FATTR4_WORD1_TIME_MODIFY_SET | FATTR4_WORD1_MOUNTED_ON_FILEID)
>
> #define NFSD4_SUPPORTED_ATTRS_WORD2 0
>
>
> ... will see
>
> Legal Disclaimer: This e-mail communication (and any attachment/s) is confidential and contains proprietary information, some or all of which may be legally privileged. It is intended solely for the use of the individual or entity to which it is addressed. Access to this email by anyone else is unauthorized. If you are not the intended recipient, any disclosure, copying, distribution or any action taken or omitted to be taken in reliance on it, is prohibited and may be unlawful.
next prev parent reply other threads:[~2022-01-06 14:28 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-17 20:48 [PATCH 0/8] Support btime and other NFSv4 specific attributes trondmy
2021-12-17 20:48 ` [PATCH 1/8] NFS: Expand the type of nfs_fattr->valid trondmy
2021-12-17 20:48 ` [PATCH 2/8] nfs: Add timecreate to nfs inode trondmy
2021-12-17 20:48 ` [PATCH 3/8] NFS: Return the file btime in the statx results when appropriate trondmy
2021-12-17 20:48 ` [PATCH 4/8] nfs: Add 'archive', 'hidden' and 'system' fields to nfs inode trondmy
2021-12-17 20:48 ` [PATCH 5/8] nfs: Add 'time backup' " trondmy
2021-12-17 20:48 ` [PATCH 6/8] NFSv4: Support the offline bit trondmy
2021-12-17 20:48 ` [PATCH 7/8] NFS: Support statx_get and statx_set ioctls trondmy
2021-12-17 20:48 ` [PATCH 8/8] NFSv4: Add an ioctl to allow retrieval of the NFS raw ACCESS mask trondmy
2021-12-21 22:20 ` Anna Schumaker
2022-01-03 20:52 ` [PATCH 7/8] NFS: Support statx_get and statx_set ioctls J. Bruce Fields
2022-01-03 20:56 ` Trond Myklebust
2022-01-03 21:47 ` bfields
2022-01-03 20:51 ` [PATCH 0/8] Support btime and other NFSv4 specific attributes J. Bruce Fields
2022-01-03 20:51 ` Trond Myklebust
2022-01-05 15:05 ` Ondrej Valousek
2022-01-05 15:10 ` Trond Myklebust
2022-01-05 15:10 ` bfields
2022-01-05 15:40 ` Ondrej Valousek
2022-01-05 15:54 ` bfields
2022-01-06 9:31 ` Ondrej Valousek
2022-01-06 14:15 ` Trond Myklebust
2022-01-06 14:19 ` Ondrej Valousek
2022-01-06 14:28 ` bfields [this message]
2022-01-06 14:36 ` bfields
2022-01-06 14:52 ` Ondrej Valousek
2022-01-06 14:55 ` bfields
2022-01-06 16:13 ` Ondrej Valousek
2022-01-06 16:59 ` Chuck Lever III
2022-01-06 18:47 ` Olga Kornievskaia
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=20220106142812.GC7105@fieldses.org \
--to=bfields@fieldses.org \
--cc=anna.schumaker@netapp.com \
--cc=linux-nfs@vger.kernel.org \
--cc=ondrej.valousek.xm@renesas.com \
--cc=trondmy@hammerspace.com \
--cc=trondmy@kernel.org \
/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).