linux/net
Sasha Levin 960994f5d1 xprtrdma: fix up the nfs/nfs-anna merge of the Write chunk head trim
Two fixes for the same Write chunk payload corruption meet in
linux-next. In the nfs tree, commit a0db57fee3 ("xprtrdma: Fix Write
chunk payload corruption on a short reply header") trims
head[0].iov_len in rpcrdma_decode_msg(). In the nfs-anna tree,
commit 9ee534a759 ("xprtrdma: trim head iovec when the payload
arrives via a Write chunk") trims it in rpcrdma_inline_fixup() and
reduces buflen by the same amount.

The merge resolution keeps the caller-side trim. By the time
rpcrdma_inline_fixup() runs, head[0].iov_len already equals copy_len,
so the block added by the nfs-anna commit never runs and its buflen
reduction in rq_rcv_buf and rq_private_buf is lost. The helper is also
still passed xdr_pad_size(writelist), while its kernel-doc now
describes @writelist as the number of bytes conveyed by the Write
chunk.

Drop the caller-side trim and pass the full Write chunk length, so
that rpcrdma_inline_fixup() is the only place that trims head[0] and
reduces buflen. Compute the pad with xdr_pad_size() in the helper, so
the padding from the nfs commit stays correct for lengths that are not
a multiple of four. Its rpclen calculation and empty reply check stay
in rpcrdma_decode_msg().

Fixes: 53ab189bdc14 ("Merge branch 'linux-next' of git://git.linux-nfs.org/projects/anna/linux-nfs.git")
Link: https://lore.kernel.org/all/as4aacUf2Q78FMvY@sirena.org.uk/
Signed-off-by: Sasha Levin <sashal@kernel.org>
Tested-by: Tim Menninger <tmenninger@everpuredata.com>
Reviewed-by: Tim Menninger <tmenninger@everpuredata.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2026-10-30 14:22:36 -10:00
..
6lowpan net: protocol: use assign_bit() where applicable 2026-09-21 17:18:54 -07:00
9p
802 llc: strip the leftovers of the llc2 removal 2026-10-01 10:07:32 +02:00
8021q Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2026-10-22 11:45:58 +02:00
atm Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2026-09-17 14:31:42 -07:00
batman-adv This feature/cleanup patchset includes the following patches: 2026-10-05 17:43:09 -07:00
bluetooth Networking changes for 7.4. 2026-10-22 15:58:00 -10:00
bpf bpf: Use the socket of a sk_lookup test run under RCU 2026-10-18 00:36:43 +00:00
bridge Current release - new code bugs: 2026-10-29 08:17:05 -10:00
can can: fix unique skb identifier regression under RPS 2026-10-01 17:05:03 +02:00
ceph The two things of note here are the disablement of inline data support 2026-10-30 09:42:10 -10:00
core vfs-7.4-rc1.fixes 2026-10-30 09:25:01 -10:00
dcb net: dcb: initialize PFC value before calling getpfccfg 2026-10-28 16:32:49 -07:00
devlink devlink: region: fix snapshot id leak on kernel-allocated ids 2026-10-27 15:41:18 -07:00
dns_resolver keys, dns: Drop unused NUL terminator from upayload->data 2026-08-10 16:20:42 -07:00
dsa net: rename skb_unshare() to skb_unclone_full() 2026-10-20 11:28:49 -07:00
ethernet net: remove IPX raw 802.3 detection from eth_type_trans() 2026-10-05 17:32:33 -07:00
ethtool net: ethtool: Introduce ethtool command to list ports 2026-10-21 16:32:04 -07:00
handshake Networking changes for 7.4. 2026-10-22 15:58:00 -10:00
hsr hsr: no longer rely on RTNL in hsr_fill_info() 2026-09-18 16:50:38 -07:00
ieee802154 net: rename skb_unshare() to skb_unclone_full() 2026-10-20 11:28:49 -07:00
ife net/sched: act_ife: Only operate on Ethernet frames 2026-08-24 11:59:59 -07:00
ipv4 Current release - new code bugs: 2026-10-29 08:17:05 -10:00
ipv6 ipv6: Protect multiple routes insertion by table lock. 2026-10-28 17:23:50 -07:00
iucv net/iucv: Add lock nesting annotation in iucv_sock_close() 2026-09-14 18:52:33 -07:00
kcm Networking changes for 7.4. 2026-10-22 15:58:00 -10:00
key net: Replace %pK output with 0 2026-09-02 18:38:16 -07:00
l2tp l2tp: snapshot sequencing state when building transmit headers 2026-10-20 11:30:20 +02:00
l3mdev
lapb
llc net: drop unused LLC-related includes 2026-10-01 10:07:32 +02:00
mac80211 net: change netdev_hw_addr_list count through helpers 2026-10-21 10:51:26 +02:00
mac802154 ieee802154: avoid deprecated .ndo_do_ioctl callback 2026-09-19 16:45:00 -07:00
mctp net: mctp: free reassembly head skb when key_add fails on SOM 2026-10-29 10:48:51 +01:00
mpls mpls: unregister sysctls before network device teardown 2026-10-15 18:01:01 -07:00
mptcp Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2026-10-22 11:45:58 +02:00
ncsi ncsi: Fix use-after-free in the VLAN id list removal 2026-10-15 18:51:28 -07:00
netfilter Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2026-10-22 11:45:58 +02:00
netlabel
netlink netlink: check sk_rcvbuf before charging the dump skb 2026-10-29 09:15:16 -07:00
nfc nfc: llcp: fix slab-out-of-bounds reads when logging service names 2026-09-23 22:13:17 +02:00
nsh
openvswitch openvswitch: use eth_type_trans_careful() in internal_dev_recv() 2026-10-29 09:11:21 -07:00
packet net/packet: check TX_RING fragments before memory accounting 2026-10-29 08:58:08 -07:00
phonet net: Replace %pK output with 0 2026-09-02 18:38:16 -07:00
psample
psp net: psp: require an established connection for association setup 2026-10-05 15:59:46 -07:00
qrtr net: qrtr: resend HELLO on MHI resume 2026-09-20 11:21:10 -07:00
rds net/rds: do not initialize transports after rds_init() failed 2026-10-27 11:30:25 +01:00
rfkill
rxrpc rxrpc: Fix return in rxrpc_recvmsg_data() for service calls 2026-10-15 11:43:02 +02:00
sched Current release - new code bugs: 2026-10-29 08:17:05 -10:00
sctp sctp: reject forged cookie peer_addr with unknown address family 2026-10-23 10:43:38 -07:00
shaper
smc Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2026-10-22 11:45:58 +02:00
strparser Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2026-10-08 22:21:56 -07:00
sunrpc xprtrdma: fix up the nfs/nfs-anna merge of the Write chunk head trim 2026-10-30 14:22:36 -10:00
switchdev
tipc tipc: fix refcount panic in tipc_rcv() when receiving shared skb 2026-10-26 16:53:05 -07:00
tls tls: Honor O_NONBLOCK in tls_sw_splice_read() 2026-10-28 16:50:20 -07:00
unix Networking changes for 7.4. 2026-10-22 15:58:00 -10:00
vmw_vsock vsock: support SO_INQ on stream sockets 2026-10-21 11:58:21 +02:00
wireless wifi: cfg80211: fix potential requested_regd leak 2026-10-14 12:19:59 +02:00
x25 net: protocol: use assign_bit() where applicable 2026-09-21 17:18:54 -07:00
xdp xsk: restore UMEM flags after failed pool assignment 2026-10-26 17:04:04 -07:00
xfrm net: skbuff: replace __skb_frag_ref() with symmetric skb_netmem_ref() 2026-10-20 11:52:46 +02:00
compat.c net: af_unix: useful handling of LSM denials on SCM_RIGHTS 2026-08-17 18:14:52 -07:00
devres.c
Kconfig net: devmem: replace gen_pool with freelist 2026-09-21 16:27:10 -07:00
Kconfig.debug
Makefile
socket.c Networking changes for 7.4. 2026-10-22 15:58:00 -10:00
sysctl_net.c net: enforce net sysctl registration 2026-08-13 13:12:21 +02:00