[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ns] Any problem with reset_rtx_timer() in tcp.cc ?




Hello!

|void TcpAgent::reset_rtx_timer(int mild, int backoff)
|{
| if (backoff)
|  rtt_backoff();
| set_rtx_timer();
| if (!mild)
|  t_seqno_ = highest_ack_ + 1;
| rtt_active_ = 0;
|}
|
|This is one of the function in tcp.cc. I guess it backoff the rto using
|rtt_backoff(). Then re-calculate rto and set the retransmission timer
|using set_rtx_timer(). Then, calculate the timing of the segment being
|timed using rtt_active = 0.
|
|However, I read TCP/IP Illustrated and according to my understanding,
|the retransmission timer should be turned off in case of duplicate ack
|and reset with the exponentially-backoff rto in case of timeout.
|
   As i understand, the RTT should not be updated on receipt of each 
   duplicate ACK and _Not_ turn off the retransmission timer. Thats
   what this function is implementing. Hence, the cancel_rtx_timer(), 
   as you have mentioned below, should not be called. The variable 'mild'
   is used so that when the reset_rtx_timer() is called on dupack_action,
   as in Reno, 't_seqno_' should not be modified.


|Therefore, should be code be
|
|    void TcpAgent::reset_rtx_timer(int mild, int backoff)
|{
| if (backoff)
|  rtt_backoff();
|
|if (mild)
|  cancel_rtx_timer()
|else
|  set_rtx_timer();
|
| if (!mild)
|  t_seqno_ = highest_ack_ + 1;
| rtt_active_ = 0;
|}
|
  
    If a retransmitted packet on Fast-Retransmit is lost, then it
    would not be recovered, if the cancel_rtx_timer() is called.

    Hope that helps, 
Thanks,
Vinay.


+---------------------------------------------------------------------------+
|  Vmail : Home (409)-846-2517 Work (409)-845-5007 Email : [email protected]  |
|         WebURL : http://www.cs.tamu.edu/people/v0s5080/index.html         |
+---------------------------------------------------------------------------+