TCP window scaling value

Status
Not open for further replies.

gaurav

New Member


Messages: 1

Hello support,

I found in file "tcp_input.c-orig" located at location "usr\src\sys\netinet" at line number 511, "tp->request_r_scale" is incremented depending on condition. 16 bits are reserved for window and its value could be MAX 30 bits.
In your if condition "TCP_MAXWIN << tp->request_r_scale < so->so_rcv.sb_hiwat", if I have "so->so_rcv.sb_hiwat" value to be 524286, then "tp->request_r_scale" is incremented four times but its value should be 3.

Reason being, while shifting TCP_MAXWIN,
1st iteration 1111111111111111 < 1111111111111111110 [TRUE]
increment once
2nd iteration 11111111111111110 < 1111111111111111110 [TRUE]
increment again
3rd iteration 111111111111111100 < 1111111111111111110 [TRUE]
increment once
4th iteration 1111111111111111000 < 1111111111111111110 [TRUE]
increment again
5th iteration 11111111111111110000 < 1111111111111111110 [FALSE]

The LSB are zeros, which should be one.

Please tell me if I am wrong.

--Gaurav Goel
 

DutchDaemon

Administrator
Staff member
Administrator
Moderator
Developer

Reaction score: 3,122
Messages: 11,416

Status
Not open for further replies.
Top