Please Pull NFS Client Updates for Linux 7.0
Subsystems (2)
Anna Schumaker
maintainerHi Linus,
The following changes since commit 24d479d26b25bce5faea3ddd9fa8f3a6c3129ea7:
Linux 6.19-rc6 (2026-01-18 15:42:45 -0800)
are available in the Git repository at:
git://git.linux-nfs.org/projects/anna/linux-nfs.git tags/nfs-for-7.0-1
for you to fetch changes up to dd2fdc3504592d85e549c523b054898a036a6afe:
SUNRPC: fix gss_auth kref leak in gss_alloc_msg error path (2026-02-09 16:39:50 -0500)
----------------------------------------------------------------
NFS Client Updates for Linux 7.0
New Features:
* Use an LRU list for returning unused delegations
* Introduce a KConfig option to disable NFS v4.0 and make NFS v4.1 the default
Bugfixes:
* NFS/localio: Handle short writes by retrying
* NFS/localio: prevent direct reclaim recursion into NFS via nfs_writepages
* NFS/localio: use GFP_NOIO and non-memreclaim workqueue in nfs_local_commit
* NFS/localio: remove -EAGAIN handling in nfs_local_doio()
* pNFS: fix a missing wake up while waiting on NFS_LAYOUT_DRAIN
* fs/nfs: Fix a readdir slow-start regression
* SUNRPC: fix gss_auth kref leak in gss_alloc_msg error path
Other Cleanups and Improvements:
* A few other NFS/localio cleanups
* Various other delegation handling cleanups from Christoph
* Unify security_inode_listsecurity() calls
* Improvements to NFSv4 lease handling
* Clean up SUNRPC *_debug fields when CONFIG_SUNRPC_DEBUG is not set
Thanks,
Anna
----------------------------------------------------------------
Anna Schumaker (14):
NFS: Move nfs40_call_sync_ops into nfs40proc.c
NFS: Split out the nfs40_reboot_recovery_ops into nfs40client.c
NFS: Split out the nfs40_nograce_recovery_ops into nfs40proc.c
NFS: Split out the nfs40_state_renewal_ops into nfs40proc.c
NFS: Split out the nfs40_mig_recovery_ops to nfs40proc.c
NFS: Move the NFS v4.0 minor version ops into nfs40proc.c
NFS: Make the various NFS v4.0 operations static again
NFS: Move nfs40_shutdown_client into nfs40client.c
NFS: Move nfs40_init_client into nfs40client.c
NFS: Move NFS v4.0 pathdown recovery into nfs40client.c
NFS: Pass a struct nfs_client to nfs4_init_sequence()
NFS: Move sequence slot operations into minorversion operations
NFS: Add a way to disable NFS v4.0 via KConfig
NFS: Merge CONFIG_NFS_V4_1 with CONFIG_NFS_V4
Ben Dooks (1):
sunrpc: rpc_debug and others are defined even if CONFIG_SUNRPC_DEBUG unset
Chen Ni (1):
nfs: nfs4proc: Convert comma to semicolon
Chenguang Zhao (1):
SUNRPC: Change list definition method
Christoph Hellwig (31):
NFS: remove __nfs_client_for_each_server
NFS: remove nfs_client_mark_return_unused_delegation_types
NFS: remove nfs_client_mark_return_all_delegations
NFS: remove the NULL inode check in nfs4_inode_return_delegation_on_close
NFS: remove nfs_inode_detach_delegation
NFS: remove nfs_start_delegation_return
NFS: assert rcu_read_lock is held in nfs_start_delegation_return_locked
NFS: drop the _locked postfix from nfs_start_delegation_return
NFS: remove NFS_DELEGATION_INODE_FREEING
NFS: open code nfs_delegation_need_return
NFS: remove nfs_free_delegation
NFS: rewrite nfs_delegations_present in terms of nr_active_delegations
NFS: move delegation lookup into can_open_delegated
NFS: return bool from nfs_detach_delegation{,_locked}
NFS: move the deleg_cur check out of nfs_detach_delegation_locked
NFS: simplify the detached delegation check in update_open_stateid
NFS: take a delegation reference in nfs4_get_valid_delegation
NFS: don't consume a delegation reference in nfs_end_delegation_return
NFS: use refcount_inc_not_zero nfs_start_delegation_return
NFS: use a local RCU critical section in nfs_start_delegation_return
NFS: reformat nfs_mark_delegation_revoked
NFS: add a separate delegation return list
NFS: return delegations from the end of a LRU when over the watermark
NFS: make nfs_mark_return_unreferenced_delegations less aggressive
NFS: return void from nfs4_inode_make_writeable
NFS: return void from ->return_delegation
NFS: use bool for the issync argument to nfs_end_delegation_return
NFS: remove the delegation == NULL check in nfs_end_delegation_return
NFS: fold nfs_abort_delegation_return into nfs_end_delegation_return
NFS: simplify error handling in nfs_end_delegation_return
NFS: fix delayed delegation return handling
Daniel Hodges (1):
SUNRPC: fix gss_auth kref leak in gss_alloc_msg error path
Mike Snitzer (4):
NFS/localio: prevent direct reclaim recursion into NFS via nfs_writepages NFS/localio: use GFP_NOIO and non-memreclaim workqueue in nfs_local_commit NFS/localio: remove -EAGAIN handling in nfs_local_doio() NFS/localio: switch nfs_local_do_read and nfs_local_do_write to return void
Olga Kornievskaia (1):
pNFS: fix a missing wake up while waiting on NFS_LAYOUT_DRAIN
Sagi Grimberg (1):
fs/nfs: Fix readdir slow-start regression
Sergey Shtylyov (2):
NFSv4: pass lease period in seconds to nfs4_set_lease_period()
NFSv4: limit lease period in nfs4_set_lease_period()
Stephen Smalley (1):
nfs: unify security_inode_listsecurity() calls
Trond Myklebust (2):
NFS/localio: Handle short writes by retrying NFS/localio: Cleanup the nfs_local_pgio_done() parameters
fs/nfs/Kconfig | 26 +- fs/nfs/Makefile | 4 +- fs/nfs/callback.c | 13 +- fs/nfs/callback.h | 3 - fs/nfs/callback_proc.c | 16 +- fs/nfs/callback_xdr.c | 21 -- fs/nfs/client.c | 12 +- fs/nfs/delegation.c | 594 +++++++++++++++--------------- fs/nfs/delegation.h | 9 +- fs/nfs/dir.c | 4 +- fs/nfs/fs_context.c | 3 +- fs/nfs/internal.h | 15 +- fs/nfs/localio.c | 126 ++++--- fs/nfs/netns.h | 4 +- fs/nfs/nfs3proc.c | 3 +- fs/nfs/nfs40.h | 19 + fs/nfs/nfs40client.c | 245 +++++++++++++ fs/nfs/nfs40proc.c | 395 ++++++++++++++++++++ fs/nfs/nfs42proc.c | 13 +- fs/nfs/nfs4_fs.h | 86 +++-- fs/nfs/nfs4client.c | 193 +--------- fs/nfs/nfs4proc.c | 804 +++++++++-------------------------------- fs/nfs/nfs4renewd.c | 15 +- fs/nfs/nfs4session.c | 4 - fs/nfs/nfs4session.h | 23 -- fs/nfs/nfs4state.c | 93 +---- fs/nfs/nfs4trace.c | 2 - fs/nfs/nfs4trace.h | 21 +- fs/nfs/nfs4xdr.c | 109 ++---- fs/nfs/pnfs.c | 3 +- fs/nfs/pnfs.h | 6 +- fs/nfs/proc.c | 3 +- fs/nfs/read.c | 4 +- fs/nfs/super.c | 30 +- fs/nfs/sysfs.c | 10 +- fs/nfs/write.c | 2 +- include/linux/nfs_fs_sb.h | 10 +- include/linux/nfs_xdr.h | 9 +- include/linux/sunrpc/debug.h | 2 - net/sunrpc/auth_gss/auth_gss.c | 3 + net/sunrpc/backchannel_rqst.c | 3 +- 41 files changed, 1372 insertions(+), 1588 deletions(-) create mode 100644 fs/nfs/nfs40.h create mode 100644 fs/nfs/nfs40client.c create mode 100644 fs/nfs/nfs40proc.c
The pull request you sent on Thu, 12 Feb 2026 17:06:25 -0500:
The pull request you sent on Thu, 12 Feb 2026 17:06:25 -0500:
Quoted 1 line
git://git.linux-nfs.org/projects/anna/linux-nfs.gittags/nfs-for-7.0-1
has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/7449f86bafcdb588422bb14a4babfd285e723670
Thank you!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/prtracker.html
Quoted 37 lines · Anna Schumaker
Hi Linus,
The following changes since commit
24d479d26b25bce5faea3ddd9fa8f3a6c3129ea7:Linux 6.19-rc6 (2026-01-18 15:42:45 -0800)
are available in the Git repository at:
git://git.linux-nfs.org/projects/anna/linux-nfs.gittags/nfs-for-7.0-1for you to fetch changes up to
dd2fdc3504592d85e549c523b054898a036a6afe:SUNRPC: fix
gss_authkref leak ingss_alloc_msgerror path (2026-02-09 16:39:50 -0500)----------------------------------------------------------------
NFS Client Updates for Linux 7.0New Features:
* Use an LRU list for returning unused delegations
* Introduce a KConfig option to disable NFS v4.0 and make NFS v4.1 the defaultBugfixes:
* NFS/localio: Handle short writes by retrying
* NFS/localio: prevent direct reclaim recursion into NFS vianfs_writepages
* NFS/localio: useGFP_NOIOand non-memreclaim workqueue innfs_local_commit
* NFS/localio: remove-EAGAINhandling innfs_local_doio()
* pNFS: fix a missing wake up while waiting onNFS_LAYOUT_DRAIN
* fs/nfs: Fix a readdir slow-start regression
* SUNRPC: fixgss_authkref leak ingss_alloc_msgerror pathOther Cleanups and Improvements:
* A few other NFS/localio cleanups
* Various other delegation handling cleanups from Christoph
* Unifysecurity_inode_listsecurity()calls
* Improvements to NFSv4 lease handling
* Clean up SUNRPC*_debugfields whenCONFIG_SUNRPC_DEBUGis not set
Quoted 2 lines
Thanks,
Anna
Hello Anna,
This seems to break my setup:
[ 103.402033] VFS: Unable to mount root fs via NFS. [ 103.402476] devtmpfs: mounted [ 103.406171] Freeing unused kernel memory: 4352K [ 103.406633] Run /sbin/init as init process [ 103.406993] with arguments: [ 103.407253] /sbin/init [ 103.407491] with environment: [ 103.407767] HOME=/ [ 103.407976] TERM=linux [ 103.408228] Run /etc/init as init process [ 103.408580] with arguments: [ 103.408841] /etc/init [ 103.409071] with environment: [ 103.409346] HOME=/ [ 103.409553] TERM=linux [ 103.409802] Run /bin/init as init process [ 103.410153] with arguments: [ 103.410414] /bin/init [ 103.410644] with environment: [ 103.410920] HOME=/ [ 103.411128] TERM=linux [ 103.411367] Run /bin/sh as init process [ 103.411703] with arguments: [ 103.411963] /bin/sh [ 103.412179] with environment: [ 103.412454] HOME=/ [ 103.412662] TERM=linux [ 103.412904] Kernel panic - not syncing: No working init found. Try passing init= option to kernel. See Linux Documentation/admin-guide/init.rst for guidance.
Doing a git bisect results in:
commit 4e0269352534715915aae3fb84dd4d3bb3ff3738
Author: Anna Schumaker <[email protected]> Date: Fri Nov 21 14:53:50 2025 -0500
NFS: Add a way to disable NFS v4.0 via KConfig
I introduce NFS4_MIN_MINOR_VERSION as a parallel to NFS4_MAX_MINOR_VERSION to check if NFS v4.0 has been compiled in and return an appropriate error if not.
Before commit above my config has:CONFIG_NFS_FS=yCONFIG_NFS_V4=yCONFIG_NFS_V4_1=yCONFIG_NFS_V4_2=y
after commit above (with make olddefconfig), my config has:CONFIG_NFS_FS=yCONFIG_NFS_V4=y
# CONFIG_NFS_V4_0 is not setCONFIG_NFS_V4_1=yCONFIG_NFS_V4_2=y
My kernel command line has:
nfsroot=192.168.1.10:/srv/nfs/rootfs,nfsvers=4
I notice that I am probably stupid who has the above, as I assumed that it meant use the best NFS 4.x version supported by the kernel.
If I change it to:
nfsroot=192.168.1.10:/srv/nfs/rootfs,nfsvers=4.2
The config:CONFIG_NFS_FS=yCONFIG_NFS_V4=y
# CONFIG_NFS_V4_0 is not setCONFIG_NFS_V4_1=yCONFIG_NFS_V4_2=y
successfully mounts my rootfs.
So AFAICT, it seems that nfsvers=4 actually means nfsvers=4.0
I am probably not the only person to who has "nfsvers=4" on the kernel command line.
Possible solutions I can see:
If the intention is for commit 4e0269352534 ("NFS: Add a way to disable NFS v4.0 via KConfig") to allow people to disable NFS 4.0, we could change the new "config NFS_V4_0" to be either "default y".
or
Perhaps we could modify "nfsvers=4" to actually mean "use whatever highest NFS 4.x version supported by the kernel", rather than use NFS 4.0 and only 4.0.
Kind regards,
Niklas
Anna Schumaker
maintainerQuoted 134 lines · Niklas Cassel
Quoted 37 lines · Anna Schumaker
Hi Linus,
The following changes since commit
24d479d26b25bce5faea3ddd9fa8f3a6c3129ea7:Linux 6.19-rc6 (2026-01-18 15:42:45 -0800)
are available in the Git repository at:
git://git.linux-nfs.org/projects/anna/linux-nfs.gittags/nfs-for-7.0-1for you to fetch changes up to
dd2fdc3504592d85e549c523b054898a036a6afe:SUNRPC: fix
gss_authkref leak ingss_alloc_msgerror path (2026-02-09 16:39:50 -0500)----------------------------------------------------------------
NFS Client Updates for Linux 7.0New Features:
* Use an LRU list for returning unused delegations
* Introduce a KConfig option to disable NFS v4.0 and make NFS v4.1 the defaultBugfixes:
* NFS/localio: Handle short writes by retrying
* NFS/localio: prevent direct reclaim recursion into NFS vianfs_writepages
* NFS/localio: useGFP_NOIOand non-memreclaim workqueue innfs_local_commit
* NFS/localio: remove-EAGAINhandling innfs_local_doio()
* pNFS: fix a missing wake up while waiting onNFS_LAYOUT_DRAIN
* fs/nfs: Fix a readdir slow-start regression
* SUNRPC: fixgss_authkref leak ingss_alloc_msgerror pathOther Cleanups and Improvements:
* A few other NFS/localio cleanups
* Various other delegation handling cleanups from Christoph
* Unifysecurity_inode_listsecurity()calls
* Improvements to NFSv4 lease handling
* Clean up SUNRPC*_debugfields whenCONFIG_SUNRPC_DEBUGis not setQuoted 2 lines
Thanks,
AnnaHello Anna,
This seems to break my setup:
[ 103.402033] VFS: Unable to mount root fs via NFS. [ 103.402476] devtmpfs: mounted [ 103.406171] Freeing unused kernel memory: 4352K [ 103.406633] Run /sbin/init as init process [ 103.406993] with arguments: [ 103.407253] /sbin/init [ 103.407491] with environment: [ 103.407767] HOME=/ [ 103.407976] TERM=linux [ 103.408228] Run /etc/init as init process [ 103.408580] with arguments: [ 103.408841] /etc/init [ 103.409071] with environment: [ 103.409346] HOME=/ [ 103.409553] TERM=linux [ 103.409802] Run /bin/init as init process [ 103.410153] with arguments: [ 103.410414] /bin/init [ 103.410644] with environment: [ 103.410920] HOME=/ [ 103.411128] TERM=linux [ 103.411367] Run /bin/sh as init process [ 103.411703] with arguments: [ 103.411963] /bin/sh [ 103.412179] with environment: [ 103.412454] HOME=/ [ 103.412662] TERM=linux [ 103.412904] Kernel panic - not syncing: No working init found. Trypassing init= option to kernel. See Linux
Documentation/admin-guide/init.rstfor guidance.Doing a git bisect results in:
commit
4e0269352534715915aae3fb84dd4d3bb3ff3738Author: Anna Schumaker <[email protected]> Date: Fri Nov 21 14:53:50 2025 -0500NFS: Add a way to disable NFS v4.0 via KConfig
I introduce
NFS4_MIN_MINOR_VERSIONas a parallel toNFS4_MAX_MINOR_VERSIONto check if NFS v4.0 has been compiled in and return an appropriate error if not.Before commit above my config has:
CONFIG_NFS_FS=yCONFIG_NFS_V4=yCONFIG_NFS_V4_1=yCONFIG_NFS_V4_2=yafter commit above (with make olddefconfig), my config has:
CONFIG_NFS_FS=yCONFIG_NFS_V4=y
#CONFIG_NFS_V4_0is not setCONFIG_NFS_V4_1=yCONFIG_NFS_V4_2=yMy kernel command line has:
nfsroot=192.168.1.10:/srv/nfs/rootfs,nfsvers=4I notice that I am probably stupid who has the above, as I assumed that it meant use the best NFS 4.x version supported by the kernel.
If I change it to:
nfsroot=192.168.1.10:/srv/nfs/rootfs,nfsvers=4.2The config:
CONFIG_NFS_FS=yCONFIG_NFS_V4=y
#CONFIG_NFS_V4_0is not setCONFIG_NFS_V4_1=yCONFIG_NFS_V4_2=ysuccessfully mounts my rootfs.
So AFAICT, it seems that nfsvers=4 actually means nfsvers=4.0
I am probably not the only person to who has "nfsvers=4" on the kernel command line.
Quoted 5 lines
Possible solutions I can see:
If the intention is for commit
4e0269352534("NFS: Add a way to disable NFS v4.0 via KConfig") to allow people to disable NFS 4.0, we could change the new "configNFS_V4_0" to be either "default y".
This is what I intended, actually. I don't know how the missing "default y" slipped through the cracks for this long. Thanks for pointing it out, I'll get this fixed up!
Anna
Quoted 11 lines
or
Perhaps we could modify "nfsvers=4" to actually mean "use whatever highest NFS 4.x version supported by the kernel", rather than use NFS 4.0 and only 4.0.
Kind regards,
Niklas
Quoted 143 lines · Anna Schumaker
Quoted 134 lines · Niklas Cassel
Quoted 37 lines · Anna Schumaker
Hi Linus,
The following changes since commit
24d479d26b25bce5faea3ddd9fa8f3a6c3129ea7:Linux 6.19-rc6 (2026-01-18 15:42:45 -0800)
are available in the Git repository at:
git://git.linux-nfs.org/projects/anna/linux-nfs.gittags/nfs-for-7.0-1for you to fetch changes up to
dd2fdc3504592d85e549c523b054898a036a6afe:SUNRPC: fix
gss_authkref leak ingss_alloc_msgerror path (2026-02-09 16:39:50 -0500)----------------------------------------------------------------
NFS Client Updates for Linux 7.0New Features:
* Use an LRU list for returning unused delegations
* Introduce a KConfig option to disable NFS v4.0 and make NFS v4.1 the defaultBugfixes:
* NFS/localio: Handle short writes by retrying
* NFS/localio: prevent direct reclaim recursion into NFS vianfs_writepages
* NFS/localio: useGFP_NOIOand non-memreclaim workqueue innfs_local_commit
* NFS/localio: remove-EAGAINhandling innfs_local_doio()
* pNFS: fix a missing wake up while waiting onNFS_LAYOUT_DRAIN
* fs/nfs: Fix a readdir slow-start regression
* SUNRPC: fixgss_authkref leak ingss_alloc_msgerror pathOther Cleanups and Improvements:
* A few other NFS/localio cleanups
* Various other delegation handling cleanups from Christoph
* Unifysecurity_inode_listsecurity()calls
* Improvements to NFSv4 lease handling
* Clean up SUNRPC*_debugfields whenCONFIG_SUNRPC_DEBUGis not setQuoted 2 lines
Thanks,
AnnaHello Anna,
This seems to break my setup:
[ 103.402033] VFS: Unable to mount root fs via NFS. [ 103.402476] devtmpfs: mounted [ 103.406171] Freeing unused kernel memory: 4352K [ 103.406633] Run /sbin/init as init process [ 103.406993] with arguments: [ 103.407253] /sbin/init [ 103.407491] with environment: [ 103.407767] HOME=/ [ 103.407976] TERM=linux [ 103.408228] Run /etc/init as init process [ 103.408580] with arguments: [ 103.408841] /etc/init [ 103.409071] with environment: [ 103.409346] HOME=/ [ 103.409553] TERM=linux [ 103.409802] Run /bin/init as init process [ 103.410153] with arguments: [ 103.410414] /bin/init [ 103.410644] with environment: [ 103.410920] HOME=/ [ 103.411128] TERM=linux [ 103.411367] Run /bin/sh as init process [ 103.411703] with arguments: [ 103.411963] /bin/sh [ 103.412179] with environment: [ 103.412454] HOME=/ [ 103.412662] TERM=linux [ 103.412904] Kernel panic - not syncing: No working init found. Trypassing init= option to kernel. See Linux
Documentation/admin-guide/init.rstfor guidance.Doing a git bisect results in:
commit
4e0269352534715915aae3fb84dd4d3bb3ff3738Author: Anna Schumaker <[email protected]> Date: Fri Nov 21 14:53:50 2025 -0500NFS: Add a way to disable NFS v4.0 via KConfig
I introduce
NFS4_MIN_MINOR_VERSIONas a parallel toNFS4_MAX_MINOR_VERSIONto check if NFS v4.0 has been compiled in and return an appropriate error if not.Before commit above my config has:
CONFIG_NFS_FS=yCONFIG_NFS_V4=yCONFIG_NFS_V4_1=yCONFIG_NFS_V4_2=yafter commit above (with make olddefconfig), my config has:
CONFIG_NFS_FS=yCONFIG_NFS_V4=y
#CONFIG_NFS_V4_0is not setCONFIG_NFS_V4_1=yCONFIG_NFS_V4_2=yMy kernel command line has:
nfsroot=192.168.1.10:/srv/nfs/rootfs,nfsvers=4I notice that I am probably stupid who has the above, as I assumed that it meant use the best NFS 4.x version supported by the kernel.
If I change it to:
nfsroot=192.168.1.10:/srv/nfs/rootfs,nfsvers=4.2The config:
CONFIG_NFS_FS=yCONFIG_NFS_V4=y
#CONFIG_NFS_V4_0is not setCONFIG_NFS_V4_1=yCONFIG_NFS_V4_2=ysuccessfully mounts my rootfs.
So AFAICT, it seems that nfsvers=4 actually means nfsvers=4.0
I am probably not the only person to who has "nfsvers=4" on the kernel command line.
Quoted 5 lines
Possible solutions I can see:
If the intention is for commit
4e0269352534("NFS: Add a way to disable NFS v4.0 via KConfig") to allow people to disable NFS 4.0, we could change the new "configNFS_V4_0" to be either "default y".
Quoted 12 lines
This is what I intended, actually. I don't know how the missing "default y" slipped through the cracks for this long. Thanks for pointing it out, I'll get this fixed up!
Anna
Quoted 6 lines
or
Perhaps we could modify "nfsvers=4" to actually mean "use whatever highest NFS 4.x version supported by the kernel", rather than use NFS 4.0 and only 4.0.
Another related problem I just encountered, when doing a bisect that pivoted from 7.0-rc1 back down to 6.19, is that "make olddefconfig" using the 7.0-rc1's .config as starting point against 6.19 kernel results in:
# CONFIG_NFS_V4_1 is not set
# CONFIG_NFS_V4_2 is not set
CONFIG_PNFS_FLEXFILE_LAYOUT=m doesn't exist, etc. So this change seriously breaks NFS bisect-ability.
Feels like the new CONFIG_NFS_V4_0 control should be standalone and CONFIG_NFS_V4_1 shouldn't be removed. But the devil is in the details I'm sure...
Mike