diff options
author | J. Bruce Fields <bfields@redhat.com> | 2012-08-17 17:31:53 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-09-14 10:00:39 -0700 |
commit | 299ee067572cf58dd38d03770263cbca212e5332 (patch) | |
tree | 7fe1fb1336c14637aeb989d154fd741bfc22d128 /drivers/pps | |
parent | e684493e06addddaf273964dff6fa0f2204953b8 (diff) |
svcrpc: fix svc_xprt_enqueue/svc_recv busy-looping
commit d10f27a750312ed5638c876e4bd6aa83664cccd8 upstream.
The rpc server tries to ensure that there will be room to send a reply
before it receives a request.
It does this by tracking, in xpt_reserved, an upper bound on the total
size of the replies that is has already committed to for the socket.
Currently it is adding in the estimate for a new reply *before* it
checks whether there is space available. If it finds that there is not
space, it then subtracts the estimate back out.
This may lead the subsequent svc_xprt_enqueue to decide that there is
space after all.
The results is a svc_recv() that will repeatedly return -EAGAIN, causing
server threads to loop without doing any actual work.
Reported-by: Michael Tokarev <mjt@tls.msk.ru>
Tested-by: Michael Tokarev <mjt@tls.msk.ru>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/pps')
0 files changed, 0 insertions, 0 deletions