netdev
[Top] [All Lists]

RE: rcv_wnd = init_cwnd*mss

To: "David S. Miller" <davem@xxxxxxxxxxxxx>
Subject: RE: rcv_wnd = init_cwnd*mss
From: "Meda, Prasanna" <pmeda@xxxxxxxxxx>
Date: Wed, 27 Oct 2004 23:15:48 -0700
Cc: <linux-kernel@xxxxxxxxxxxxxxx>, <netdev@xxxxxxxxxxx>, <davem@xxxxxxxxxx>
Sender: netdev-bounce@xxxxxxxxxxx
Thread-index: AcS8rx0lII4RnMC0R0WeBsZWJg685QABCWEw
Thread-topic: rcv_wnd = init_cwnd*mss
> From: David S. Miller [mailto:davem@xxxxxxxxxxxxx]
> Sent: Wednesday, October 27, 2004 10:21 PM
> To: Meda, Prasanna
> Cc: linux-kernel@xxxxxxxxxxxxxxx; netdev@xxxxxxxxxxx; davem@xxxxxxxxxx
> Subject: Re: rcv_wnd = init_cwnd*mss
>
>
> On Wed, 27 Oct 2004 22:14:33 -0700
> "Meda, Prasanna" <pmeda@xxxxxxxxxx> wrote:
>
> > 
> > What is the reason for checking mss with 1<<rcv_wscale?
> > include/net/tcp.h:

> Because the advertised window field is 16-bits.  It is
> interpreted as "value << rcv_wscale"

Thanks, still it is unclear to me why are we
downsizing the advertised window(rcv_wnd) to cwnd? 
To defeat disobeying sender, or something like below?

Suppose when wscale is zero, it is now checking mss > 1,
and perhaps the intention was to check mss > rcv_wnd,
where mss is greater than advertised, and we still
want to advertise window to spwan 2 to 4 cwnd packets.

And also in the following line,
if (*rcv_wscale && sysctl_tcp_app_win && space>=mss &&
                    space - max((space>>sysctl_tcp_app_win), mss>>*rcv_wscale) <
65536/2)

space is actual_space>>rcv_wscale, mss is actual value.
Why are we checking space>=mss, which are in different
scales? The second line is doing max on space and mss 
on same scales, and looks right.


Thanks,
Prasanna.


<Prev in Thread] Current Thread [Next in Thread>