]> err.no Git - linux-2.6/blobdiff - net/ipv4/tcp_output.c
mib: add struct net to ICMPMSGIN_INC_STATS_BH
[linux-2.6] / net / ipv4 / tcp_output.c
index e399bde7813a9057bcd4b764120854aa558d5df7..edef2afe905e14ebccf5b5e7b98eaf84363775ba 100644 (file)
@@ -5,8 +5,6 @@
  *
  *             Implementation of the Transmission Control Protocol(TCP).
  *
- * Version:    $Id: tcp_output.c,v 1.146 2002/02/01 22:01:04 davem Exp $
- *
  * Authors:    Ross Biro
  *             Fred N. van Kempen, <waltje@uWalt.NL.Mugnet.ORG>
  *             Mark Evans, <evansmp@uhura.aston.ac.uk>
@@ -607,7 +605,6 @@ static int tcp_transmit_skb(struct sock *sk, struct sk_buff *skb, int clone_it,
                                               md5,
                                               sk, NULL, NULL,
                                               tcp_hdr(skb),
-                                              sk->sk_protocol,
                                               skb->len);
        }
 #endif
@@ -1988,14 +1985,17 @@ void tcp_xmit_retransmit_queue(struct sock *sk)
 
                        if (sacked & TCPCB_LOST) {
                                if (!(sacked & (TCPCB_SACKED_ACKED|TCPCB_SACKED_RETRANS))) {
+                                       int mib_idx;
+
                                        if (tcp_retransmit_skb(sk, skb)) {
                                                tp->retransmit_skb_hint = NULL;
                                                return;
                                        }
                                        if (icsk->icsk_ca_state != TCP_CA_Loss)
-                                               NET_INC_STATS_BH(LINUX_MIB_TCPFASTRETRANS);
+                                               mib_idx = LINUX_MIB_TCPFASTRETRANS;
                                        else
-                                               NET_INC_STATS_BH(LINUX_MIB_TCPSLOWSTARTRETRANS);
+                                               mib_idx = LINUX_MIB_TCPSLOWSTARTRETRANS;
+                                       NET_INC_STATS_BH(mib_idx);
 
                                        if (skb == tcp_write_queue_head(sk))
                                                inet_csk_reset_xmit_timer(sk, ICSK_TIME_RETRANS,
@@ -2131,6 +2131,8 @@ void tcp_send_active_reset(struct sock *sk, gfp_t priority)
        TCP_SKB_CB(skb)->when = tcp_time_stamp;
        if (tcp_transmit_skb(sk, skb, 0, priority))
                NET_INC_STATS(LINUX_MIB_TCPABORTFAILED);
+
+       TCP_INC_STATS(TCP_MIB_OUTRSTS);
 }
 
 /* WARNING: This routine must only be called when we have already sent
@@ -2264,7 +2266,7 @@ struct sk_buff *tcp_make_synack(struct sock *sk, struct dst_entry *dst,
                tp->af_specific->calc_md5_hash(md5_hash_location,
                                               md5,
                                               NULL, dst, req,
-                                              tcp_hdr(skb), sk->sk_protocol,
+                                              tcp_hdr(skb),
                                               skb->len);
        }
 #endif