Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755274Ab3EURaY (ORCPT ); Tue, 21 May 2013 13:30:24 -0400 Received: from webmail.solarflare.com ([12.187.104.25]:60062 "EHLO webmail.solarflare.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753764Ab3EURaX (ORCPT ); Tue, 21 May 2013 13:30:23 -0400 Message-ID: <1369157418.2615.30.camel@bwh-desktop.uk.solarflarecom.com> Subject: Re: [PATCH v4 net-next 2/4] tcp: add TCP support for low latency receive poll. From: Ben Hutchings To: Eliezer Tamir CC: Dave Miller , , , Jesse Brandeburg , Don Skidmore , , Willem de Bruijn , Andi Kleen , HPA , Or Gerlitz , Eilon Greenstien , Eliezer Tamir Date: Tue, 21 May 2013 18:30:18 +0100 In-Reply-To: <20130521142659.18498.1984.stgit@ladj378.jer.intel.com> References: <20130521142641.18498.52856.stgit@ladj378.jer.intel.com> <20130521142659.18498.1984.stgit@ladj378.jer.intel.com> Organization: Solarflare Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.2.3 (3.2.3-3.fc16) Content-Transfer-Encoding: 7bit MIME-Version: 1.0 X-Originating-IP: [10.17.20.137] X-TM-AS-Product-Ver: SMEX-10.0.0.1412-7.000.1014-19882.005 X-TM-AS-Result: No--3.499400-0.000000-31 X-TM-AS-User-Approved-Sender: Yes X-TM-AS-User-Blocked-Sender: No Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1491 Lines: 44 On Tue, 2013-05-21 at 17:27 +0300, Eliezer Tamir wrote: > adds busy-poll support for TCP. > > Signed-off-by: Alexander Duyck > Signed-off-by: Jesse Brandeburg > Tested-by: Willem de Bruijn > Signed-off-by: Eliezer Tamir > --- > > net/ipv4/tcp.c | 9 +++++++++ > net/ipv4/tcp_input.c | 4 ++++ > 2 files changed, 13 insertions(+), 0 deletions(-) > > diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c > index dcb116d..b9cc512 100644 > --- a/net/ipv4/tcp.c > +++ b/net/ipv4/tcp.c [...] > @@ -1551,6 +1553,12 @@ int tcp_recvmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg, > struct sk_buff *skb; > u32 urg_hole = 0; > > +#ifdef CONFIG_INET_LL_RX_POLL > + if (sk_valid_ll(sk) && skb_queue_empty(&sk->sk_receive_queue) > + && (sk->sk_state == TCP_ESTABLISHED)) > + sk_poll_ll(sk, nonblock); > +#endif [...] I don't think the #ifdef is needed; this should compile down to nothing if the config option is disabled. Ben. -- Ben Hutchings, Staff Engineer, Solarflare Not speaking for my employer; that's the marketing department's job. They asked us to note that Solarflare product names are trademarked. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/