lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 07 Jan 2009 17:14:26 +0100
From:	Arnd Hannemann <hannemann@...s.rwth-aachen.de>
To:	Ilpo Järvinen <ilpo.jarvinen@...sinki.fi>
Cc:	LKML <linux-kernel@...r.kernel.org>,
	Netdev <netdev@...r.kernel.org>
Subject: Re: [PATCH][TCP]: simplify tcp_mark_lost_retrans()

Ilpo Järvinen schrieb:
> On Wed, 7 Jan 2009, Arnd Hannemann wrote:
>
>   
>> I noticed
>>     
>
> Good that somebody else is looking TCP code besides me... :-)
>   
Well I try hard... ;-)
>   
>> that in tcp_mark_lost_retrans the for-loop is only entered
>> if tcp_is_fack(tp) evaluates to true:
>>
>>           if (!tcp_is_fack(tp) || !tp->retrans_out ||
>>               !after(received_upto, tp->lost_retrans_low) ||
>>               icsk->icsk_ca_state != TCP_CA_Recovery)
>>                   return;
>>
>> Therefore the following check in the for-loop seems to be redundant,
>> because it always evaluates to true:
>>
>>                      (tcp_is_fack(tp) ||
>>                       !before(received_upto,
>>                               ack_seq + tp->reordering * tp->mss_cache))
>>
>> Did I miss something?
>>     
>
> It was just a left over from the RFC3517 SACK addition which added that 
> !tcp_is_fack(tp) there above. ...It would have been nice to have similar 
> lost rexmit feature without FACK as well but calculating that wasn't 
> trivial (or I didn't find that too trivial) and could end up being 
> extremely expensive in case of large holes. (So I also left it there as 
> sort of reminder).
>   
Perhaps it would be better to let the comments reflect
what you just said and remove the redundant check
anyway to reduce the dead code a newcomer has to understand ;-)
I would have included a patch for the comments, but as you have a
deeper understanding of the code it would probably
be better if you can do it.

Best regards,
Arnd



--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ