View | Details | Raw Unified | Return to bug 2873
Collapse All | Expand All

(-)a/src/internet/model/tcp-scalable.cc (+2 lines)
 Lines 91-96   TcpScalable::CongestionAvoidance (Ptr<TcpSocketState> tcb, Link Here 
91
  NS_LOG_FUNCTION (this << tcb << segmentsAcked);
91
  NS_LOG_FUNCTION (this << tcb << segmentsAcked);
92
92
93
  uint32_t segCwnd = tcb->GetCwndInSegments ();
93
  uint32_t segCwnd = tcb->GetCwndInSegments ();
94
  NS_ASSERT (segCwnd >= 1);
95
94
  uint32_t oldCwnd = segCwnd;
96
  uint32_t oldCwnd = segCwnd;
95
  uint32_t w = std::min (segCwnd, m_aiFactor);
97
  uint32_t w = std::min (segCwnd, m_aiFactor);
96
98
(-)a/src/internet/model/tcp-yeah.cc (-2 / +5 lines)
 Lines 326-332   TcpYeah::GetSsThresh (Ptr<const TcpSocketState> tcb, Link Here 
326
      NS_LOG_LOGIC ("Not competing with Reno flows upon loss");
326
      NS_LOG_LOGIC ("Not competing with Reno flows upon loss");
327
      reduction = m_lastQ;
327
      reduction = m_lastQ;
328
      reduction = std::max (reduction, segBytesInFlight >> m_delta);
328
      reduction = std::max (reduction, segBytesInFlight >> m_delta);
329
      reduction = std::min (reduction, std::max (segBytesInFlight >> 1, (uint32_t) 2));
329
      reduction = std::min (reduction, std::max (segBytesInFlight >> 1, 2U));
330
    }
330
    }
331
  else
331
  else
332
    { // Competing with Reno flows
332
    { // Competing with Reno flows
 Lines 339-345   TcpYeah::GetSsThresh (Ptr<const TcpSocketState> tcb, Link Here 
339
  m_fastCount = 0;
339
  m_fastCount = 0;
340
  m_renoCount = std::max (m_renoCount >> 1, (uint32_t) 2);
340
  m_renoCount = std::max (m_renoCount >> 1, (uint32_t) 2);
341
341
342
  return (bytesInFlight - (reduction * tcb->m_segmentSize));
342
  // Allow, at least, 2 segment to go out
343
  uint32_t ret = std::max (bytesInFlight - (reduction * tcb->m_segmentSize),
344
                           2U * tcb->m_segmentSize);
345
  return ret;
343
}
346
}
344
347
345
} // namespace ns3
348
} // namespace ns3

Return to bug 2873