[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1342530654.2626.563.camel@edumazet-glaptop>
Date: Tue, 17 Jul 2012 15:10:54 +0200
From: Eric Dumazet <eric.dumazet@...il.com>
To: Krishna Kumar <krkumar2@...ibm.com>
Cc: davem@...emloft.net, netdev@...r.kernel.org
Subject: Re: [PATCH] [RFC] tcp: TSQ - do not always throttle.
On Tue, 2012-07-17 at 17:33 +0530, Krishna Kumar wrote:
> Do not throttle if sysctl_tcp_limit_output_bytes==0.
>
> Maybe it is better to throttle earlier in the loop, after
> calling tcp_init_tso_segs().
>
I wonder why, and why you put this question in a changelog instead of
outside of it...
Idea was to avoid setting TSQ_THROTTLED if we break out the loop.
About disabling TSQ, my initial intent was to instead use a negative
sysctl_tcp_limit_output_bytes value.
Thats why I have in tcp_transmit_skb() :
skb->destructor = (sysctl_tcp_limit_output_bytes > 0) ?
tcp_wfree : sock_wfree;
So I suggest you change the tcp_write_xmit(() test to a single unsigned
compare :
if (atomic_read(&sk->sk_wmem_alloc) >=
(unsigned) sysctl_tcp_limit_output_bytes) {
Also use :
skb->destructor = (sysctl_tcp_limit_output_bytes >= 0) ?
tcp_wfree : sock_wfree;
and document the 'negative value disables TSQ' in
Documentation/networking/ip-sysctl.txt
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists