aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/tcp_timer.c
diff options
context:
space:
mode:
authorIlpo Järvinen <ilpo.jarvinen@helsinki.fi>2007-08-09 08:14:46 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2007-10-10 19:48:00 -0400
commite60402d0a909ca2e6e2fbdf9ed004ef0fae36d33 (patch)
treeb40a00b801cf44f81bebd7dadddb19c0086b145c /net/ipv4/tcp_timer.c
parentb9c4595bc4947faa236a849324fe3492e388d949 (diff)
[TCP]: Move sack_ok access to obviously named funcs & cleanup
Previously code had IsReno/IsFack defined as macros that were local to tcp_input.c though sack_ok field has user elsewhere too for the same purpose. This changes them to static inlines as preferred according the current coding style and unifies the access to sack_ok across multiple files. Magic bitops of sack_ok for FACK and DSACK are also abstracted to functions with appropriate names. Note: - One sack_ok = 1 remains but that's self explanary, i.e., it enables sack - Couple of !IsReno cases are changed to tcp_is_sack - There were no users for IsDSack => I dropped it Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/tcp_timer.c')
-rw-r--r--net/ipv4/tcp_timer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/tcp_timer.c b/net/ipv4/tcp_timer.c
index e9b151b3a598..d8970ecfcfc8 100644
--- a/net/ipv4/tcp_timer.c
+++ b/net/ipv4/tcp_timer.c
@@ -315,7 +315,7 @@ static void tcp_retransmit_timer(struct sock *sk)
315 if (icsk->icsk_retransmits == 0) { 315 if (icsk->icsk_retransmits == 0) {
316 if (icsk->icsk_ca_state == TCP_CA_Disorder || 316 if (icsk->icsk_ca_state == TCP_CA_Disorder ||
317 icsk->icsk_ca_state == TCP_CA_Recovery) { 317 icsk->icsk_ca_state == TCP_CA_Recovery) {
318 if (tp->rx_opt.sack_ok) { 318 if (tcp_is_sack(tp)) {
319 if (icsk->icsk_ca_state == TCP_CA_Recovery) 319 if (icsk->icsk_ca_state == TCP_CA_Recovery)
320 NET_INC_STATS_BH(LINUX_MIB_TCPSACKRECOVERYFAIL); 320 NET_INC_STATS_BH(LINUX_MIB_TCPSACKRECOVERYFAIL);
321 else 321 else