From: David S. Miller Date: Mon, 5 Jan 2009 08:59:00 +0000 (-0800) Subject: tcp: Kill extraneous SPLICE_F_NONBLOCK checks. X-Git-Tag: v2.6.29-rc1~502^2~13 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=7945cc6464a4db0caf6dfacdfe05806051c4cb7b;p=linux-2.6-omap-h63xx.git 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 --- diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c index bce1b068f2a..35bcddf8a93 100644 --- a/net/ipv4/tcp.c +++ b/net/ipv4/tcp.c @@ -597,10 +597,6 @@ ssize_t tcp_splice_read(struct socket *sock, loff_t *ppos, ret = -ENOTCONN; break; } - if (flags & SPLICE_F_NONBLOCK) { - ret = -EAGAIN; - break; - } if (!timeo) { ret = -EAGAIN; break;