1
0
Fork 0
alistair23-linux/include/linux/sunrpc
Chuck Lever 512570b178 nfsd: Fix NFSv4 READ on RDMA when using readv
commit 412055398b upstream.

svcrdma expects that the payload falls precisely into the xdr_buf
page vector. This does not seem to be the case for
nfsd4_encode_readv().

This code is called only when fops->splice_read is missing or when
RQ_SPLICE_OK is clear, so it's not a noticeable problem in many
common cases.

Add new transport method: ->xpo_read_payload so that when a READ
payload does not fit exactly in rq_res's page vector, the XDR
encoder can inform the RPC transport exactly where that payload is,
without the payload's XDR pad.

That way, when a Write chunk is present, the transport knows what
byte range in the Reply message is supposed to be matched with the
chunk.

Note that the Linux NFS server implementation of NFS/RDMA can
currently handle only one Write chunk per RPC-over-RDMA message.
This simplifies the implementation of this fix.

Fixes: b042098063 ("nfsd4: allow exotic read compounds")
Buglink: https://bugzilla.kernel.org/show_bug.cgi?id=198053
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Cc: Timo Rothenpieler <timo@rothenpieler.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-08-11 15:33:42 +02:00
..
addr.h
auth.h SUNRPC: Add rpc_auth::au_ralign field 2019-02-14 11:48:36 -05:00
auth_gss.h
bc_xprt.h SUNRPC: Destroy the back channel when we destroy the host transport 2019-10-30 12:04:35 -04:00
cache.h sunrpc: add a new cache_detail operation for when a cache is flushed 2019-08-19 11:00:39 -04:00
clnt.h NFSv4.1: fix handling of backchannel binding in BIND_CONN_TO_SESSION 2020-05-06 08:15:05 +02:00
debug.h
gss_api.h sunrpc: clean up properly in gss_mech_unregister() 2020-06-22 09:31:24 +02:00
gss_asn1.h
gss_err.h
gss_krb5.h SUNRPC: Add "@len" parameter to gss_unwrap() 2020-05-20 08:20:04 +02:00
gss_krb5_enctypes.h SUNRPC: Add build option to disable support for insecure enctypes 2019-02-13 13:33:12 -05:00
metrics.h SUNRPC: Count ops completing with tk_status < 0 2019-07-06 14:54:51 -04:00
msg_prot.h
rpc_pipe_fs.h
rpc_rdma.h
sched.h NFS Client Updates for Linux 5.3 2019-09-26 12:20:14 -07:00
stats.h
svc.h nfsd: Fix NFSv4 READ on RDMA when using readv 2020-08-11 15:33:42 +02:00
svc_rdma.h nfsd: Fix NFSv4 READ on RDMA when using readv 2020-08-11 15:33:42 +02:00
svc_xprt.h nfsd: Fix NFSv4 READ on RDMA when using readv 2020-08-11 15:33:42 +02:00
svcauth.h SUNRPC: Add lockless lookup of the server's auth domain 2018-10-03 11:32:59 -04:00
svcauth_gss.h sunrpc: clean up properly in gss_mech_unregister() 2020-06-22 09:31:24 +02:00
svcsock.h SUNRPC: Cache the process user cred in the RPC server listener 2019-04-24 09:46:35 -04:00
timer.h
types.h
xdr.h SUNRPC: Revert 241b1f419f ("SUNRPC: Remove xdr_buf_trim()") 2020-05-20 08:20:39 +02:00
xprt.h SUNRPC: Dequeue the request from the receive queue while we're re-encoding 2019-09-17 15:14:11 -04:00
xprtmultipath.h SUNRPC: Add basic load balancing to the transport switch 2019-07-06 14:54:49 -04:00
xprtrdma.h xprtrdma: Boost client's max slot table size to match Linux server 2019-08-20 11:17:16 -04:00
xprtsock.h SUNRPC: fix race to sk_err after xs_error_report 2019-10-10 16:14:28 -04:00