Linux NFS development
 help / color / mirror / Atom feed
From: Mike Snitzer <snitzer@kernel.org>
To: Anna Schumaker <anna@kernel.org>
Cc: Trond Myklebust <trondmy@kernel.org>,
	Tom Haynes <loghyr@hammerspace.com>, Chuck Lever <cel@kernel.org>,
	linux-nfs@vger.kernel.org
Subject: Re: [PATCH 1/4] nfs4.2: add nfs4_2.x to generate the UNCACHEABLE_FILE_DATA attribute
Date: Thu, 25 Jun 2026 13:31:22 -0400	[thread overview]
Message-ID: <aj1l6i8ebnkHu67U@kernel.org> (raw)
In-Reply-To: <16ff281b-f776-4e6c-9f2a-83c03f0d6eae@app.fastmail.com>

On Thu, Jun 25, 2026 at 10:26:22AM -0400, Anna Schumaker wrote:
> Hi Mike,
> 
> On Wed, Jun 24, 2026, at 3:17 PM, Mike Snitzer wrote:
> > Introduce Documentation/sunrpc/xdr/nfs4_2.x for NFSv4.2 protocol
> > extensions and define the UNCACHEABLE_FILE_DATA attribute (attr 87)
> > there, verbatim from draft-ietf-nfsv4-uncacheable-files Section 7:
> >
> >   typedef bool            fattr4_uncacheable_file_data;
> >   const FATTR4_UNCACHEABLE_FILE_DATA      = 87;
> >
> > This mirrors how the sibling NFSv4.2 attributes (FATTR4_OFFLINE=83,
> > FATTR4_TIME_DELEG_*=84/85, FATTR4_OPEN_ARGUMENTS=86) are defined in
> > Documentation/sunrpc/xdr/nfs4_1.x and generated by
> > tools/net/sunrpc/xdrgen into <linux/sunrpc/xdrgen/nfs4_1.h>, which
> > nfs4.h already includes.
> >
> > Wire the fs/nfsd "make xdrgen" target to generate the definitions header
> > <linux/sunrpc/xdrgen/nfs4_2.h> and include it from <linux/nfs4.h>, so the
> > generated FATTR4_UNCACHEABLE_FILE_DATA constant and the
> > NFS4_fattr4_uncacheable_file_data_sz size macro are available to the
> > NFSv4.2 client support that follows.
> 
> Aren't these client side changes? The xdrgen stuff is used on the
> server-side. I wouldn't expect any of these values to be available
> if nfsd is kconfig-ed off.

The NFS4.x client code needs and has access to NFS spec definitions
also, via <linux/nfs4.h>.

Its only that the server side's xdrgen framework is needed to generate
updates to the headers.  So you'll note that I have also included in
this commit the gnerated output of <linux/sunrpc/xdrgen/nfs4_2.h>.
Even if NFSD weren't Kconfig'd on, the NFS client code still has the
benefit of these NFS spec definitions via <linux/nfs4.h> (and its
inclusion of previously generated <linux/sunrpc/xdrgen/nfs4_1.h> and
now <linux/sunrpc/xdrgen/nfs4_2.h>).

Getting xdrgen to build and verify it to work took effort (Chuck uses
recent Fedora AFAIK, I happen to be using EL9.6 in this container, but
Claude code helped me cut through the missing deps pretty quickly).

So to be clear: the Linux kernel build (and NFS client build) isn't
dependent on xdrgen running at build time.

Tangential but related: maybe the xdrgen stuff should get lifted to
fs/nfs_common/ ?  Or we're fine with it living with NFS server?

Thanks,
Mike

  reply	other threads:[~2026-06-25 17:31 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-24 19:17 [PATCH 0/4] nfs: NFSv4.2 client support for UNCACHEABLE_FILE_DATA Mike Snitzer
2026-06-24 19:17 ` [PATCH 1/4] nfs4.2: add nfs4_2.x to generate the UNCACHEABLE_FILE_DATA attribute Mike Snitzer
2026-06-25 14:26   ` Anna Schumaker
2026-06-25 17:31     ` Mike Snitzer [this message]
2026-06-25 18:08       ` Chuck Lever
2026-06-24 19:17 ` [PATCH 2/4] nfs4.2: add UNCACHEABLE_FILE_DATA attribute support Mike Snitzer
2026-06-25 14:56   ` Anna Schumaker
2026-06-25 17:51     ` Mike Snitzer
2026-06-24 19:17 ` [PATCH 3/4] nfs4.2: request UNCACHEABLE_FILE_DATA only for regular files Mike Snitzer
2026-06-24 19:17 ` [PATCH 4/4] nfs4.2: open UNCACHEABLE_FILE_DATA files with O_DIRECT Mike Snitzer

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=aj1l6i8ebnkHu67U@kernel.org \
    --to=snitzer@kernel.org \
    --cc=anna@kernel.org \
    --cc=cel@kernel.org \
    --cc=linux-nfs@vger.kernel.org \
    --cc=loghyr@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