summaryrefslogtreecommitdiffstats
path: root/net/sunrpc/svc_xprt.c
diff options
context:
space:
mode:
authorJ. Bruce Fields <bfields@redhat.com>2011-01-02 21:56:36 -0500
committerJ. Bruce Fields <bfields@redhat.com>2011-01-04 16:49:22 -0500
commit9e701c610923aaeac8b38b9202a686d1cc9ee35d (patch)
tree1b2d65df63858a2cd35a4154e6d8a9fea3e716a3 /net/sunrpc/svc_xprt.c
parentd76d1815f3e72fb627ad7f95ef63120b0a557c9c (diff)
downloadop-kernel-dev-9e701c610923aaeac8b38b9202a686d1cc9ee35d.zip
op-kernel-dev-9e701c610923aaeac8b38b9202a686d1cc9ee35d.tar.gz
svcrpc: simpler request dropping
Currently we use -EAGAIN returns to determine when to drop a deferred request. On its own, that is error-prone, as it makes us treat -EAGAIN returns from other functions specially to prevent inadvertent dropping. So, use a flag on the request instead. Returning an error on request deferral is still required, to prevent further processing, but we no longer need worry that an error return on its own could result in a drop. Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'net/sunrpc/svc_xprt.c')
-rw-r--r--net/sunrpc/svc_xprt.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/sunrpc/svc_xprt.c b/net/sunrpc/svc_xprt.c
index 5eae53b..173f3b9 100644
--- a/net/sunrpc/svc_xprt.c
+++ b/net/sunrpc/svc_xprt.c
@@ -1019,6 +1019,7 @@ static struct cache_deferred_req *svc_defer(struct cache_req *req)
}
svc_xprt_get(rqstp->rq_xprt);
dr->xprt = rqstp->rq_xprt;
+ rqstp->rq_dropme = true;
dr->handle.revisit = svc_revisit;
return &dr->handle;
OpenPOWER on IntegriCloud