FAILED: patch "[PATCH] xprtrdma: Return -ENOBUFS when no pages are available" failed to apply to 4.9-stable tree
Subsystems (4)
[email protected]
maintainerThe patch below does not apply to the 4.9-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
Quoted 1 line
From
a8f688ec437dc2045cc8f0c89fe877d5803850daMon Sep 17 00:00:00 2001
From: Chuck Lever <[email protected]>
Date: Fri, 4 May 2018 15:35:46 -0400
Subject: [PATCH] xprtrdma: Return -ENOBUFS when no pages are available
The use of -EAGAIN in rpcrdma_convert_iovs() is a latent bug: the transport never calls xprt_write_space() when more pages become available. -ENOBUFS will trigger the correct "delay briefly and call again" logic.
net/sunrpc/xprtrdma/rpc_rdma.c +1 -1
@@ -231,7 +231,7 @@ rpcrdma_convert_iovs(struct rpcrdma_xprt *r_xprt, struct xdr_buf *xdrbuf,*/ *ppages =alloc_page (GFP_ATOMIC );if (!*ppages) -return -EAGAIN ; +return -ENOBUFS ; } seg->mr_page = *ppages; seg->mr_offset = (char *)page_base;
Hi Greg,
Quoted 5 lines · On Sun, Jul 01, 2018 at 11:52:35AM +0200, [email protected] wrote:
The patch below does not apply to the 4.9-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.
The attached backported patch should apply to 4.9-stable.
--
Regards
Sudip
Quoted 1 line
From
9562dcbaa81ad0853f0971e050cc9972c7af3d40Mon Sep 17 00:00:00 2001
From: Chuck Lever <[email protected]>
Date: Fri, 4 May 2018 15:35:46 -0400
Subject: [PATCH] xprtrdma: Return -ENOBUFS when no pages are available
commit a8f688ec437dc2045cc8f0c89fe877d5803850da upstream
The use of -EAGAIN in rpcrdma_convert_iovs() is a latent bug: the transport never calls xprt_write_space() when more pages become available. -ENOBUFS will trigger the correct "delay briefly and call again" logic.
--- net/sunrpc/xprtrdma/rpc_rdma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
net/sunrpc/xprtrdma/rpc_rdma.c +1 -1
@@ -229,7 +229,7 @@ rpcrdma_convert_iovs(struct rpcrdma_xprt *r_xprt, struct xdr_buf *xdrbuf,/* alloc the pagelist for receiving buffer */ ppages[p] =alloc_page (GFP_ATOMIC );if (!ppages[p]) -return -EAGAIN ; +return -ENOBUFS ; } seg[n].mr_page = ppages[p]; seg[n].mr_offset = (void *)(unsigned long ) page_base;
Signature · 1 line
2.11.0
Greg KH
maintainerQuoted 10 lines · Sudip Mukherjee
Hi Greg,
Quoted 5 lines · On Sun, Jul 01, 2018 at 11:52:35AM +0200, [email protected] wrote:
The patch below does not apply to the 4.9-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.The attached backported patch should apply to 4.9-stable.
Now applied, thanks.
greg k-h