From: Eric Dumazet <eric.duma...@gmail.com>
Date: Wed, 22 Apr 2015 12:12:20 -0700

> On Wed, 2015-04-22 at 14:50 -0400, David Miller wrote:
>> From: Eric Dumazet <eric.duma...@gmail.com>
>> Date: Wed, 22 Apr 2015 11:39:27 -0700
>> 
>> > Note that in the unlikely case skb can not be allocated,
>> > if an already transmitted packet is in the write queue, we also can OR
>> > the FIN flag on it, and rely on normal rtx to deliver this FIN later.
>> > 
>> > I'll cook a patch when net-next reopens.
>> 
>> Hmmm, we already check for something like this at the beginning of
>> tcp_send_fin(), I know because I added that piece of code 15+ years
>> ago :-)
>> 
>> Or are you suggesting something slightly different?
> 
> 
> The existing test does the OR only if there is an unsent frame in the
> write queue.
> 
> Because if the frame present in write queue was already sent, we prefer
> cooking a fresh skb to be able to send it right now (disabling Nagle
> checks)
> 
> So, in the case we cannot allocate the skb, we can still add the FIN
> flag, but not push any frame right now.
> 
> FIN will be sent later, because incoming ACK or rtx will eventually send
> it.
> 
> This sounds better than not sending FIN at all.

Ok, that makes a lot of sense.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to