From 7945cc6464a4db0caf6dfacdfe05806051c4cb7b Mon Sep 17 00:00:00 2001 From: "David S. Miller" Date: Mon, 5 Jan 2009 00:59:00 -0800 Subject: 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 --- net/ipv4/tcp.c | 4 ---- 1 file changed, 4 deletions(-) (limited to 'net/ipv4/tcp.c') 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; -- cgit v1.2.3