Commit 7945cc6464a4db0caf6dfacdfe05806051c4cb7b

Authored by David S. Miller
1 parent 4f7d54f59b

tcp: Kill extraneous SPLICE_F_NONBLOCK checks.

In splice TCP receive, the SPLICE_F_NONBLOCK flag is used
to compute the "timeo" value.  So checking it again inside
of the main receive loop to trigger -EAGAIN processing is
entirely unnecessary.

Noticed by Jarek P. and Lennert Buytenhek.

Signed-off-by: David S. Miller <davem@davemloft.net>

Showing 1 changed file with 0 additions and 4 deletions Side-by-side Diff

... ... @@ -597,10 +597,6 @@
597 597 ret = -ENOTCONN;
598 598 break;
599 599 }
600   - if (flags & SPLICE_F_NONBLOCK) {
601   - ret = -EAGAIN;
602   - break;
603   - }
604 600 if (!timeo) {
605 601 ret = -EAGAIN;
606 602 break;