[INET]: Introduce inet_sk_rebuild_header
[deliverable/linux.git] / include / net / tcp.h
index b19238027da87b5960ef5d772f686d264af01744..0c769adb0463a00e035151a558eae1bb6987ae16 100644 (file)
@@ -306,7 +306,7 @@ extern kmem_cache_t *tcp_timewait_cachep;
 static inline void tcp_tw_put(struct tcp_tw_bucket *tw)
 {
        if (atomic_dec_and_test(&tw->tw_refcnt)) {
-#ifdef INET_REFCNT_DEBUG
+#ifdef SOCK_REFCNT_DEBUG
                printk(KERN_DEBUG "tw_bucket %p released\n", tw);
 #endif
                kmem_cache_free(tcp_timewait_cachep, tw);
@@ -799,8 +799,6 @@ extern void                 tcp_parse_options(struct sk_buff *skb,
  *     TCP v4 functions exported for the inet6 API
  */
 
-extern int                     tcp_v4_rebuild_header(struct sock *sk);
-
 extern int                     tcp_v4_build_header(struct sock *sk, 
                                                    struct sk_buff *skb);
 
@@ -860,9 +858,10 @@ extern void tcp_send_probe0(struct sock *);
 extern void tcp_send_partial(struct sock *);
 extern int  tcp_write_wakeup(struct sock *);
 extern void tcp_send_fin(struct sock *sk);
-extern void tcp_send_active_reset(struct sock *sk, int priority);
+extern void tcp_send_active_reset(struct sock *sk,
+                                  unsigned int __nocast priority);
 extern int  tcp_send_synack(struct sock *);
-extern void tcp_push_one(struct sock *, unsigned mss_now);
+extern void tcp_push_one(struct sock *, unsigned int mss_now);
 extern void tcp_send_ack(struct sock *sk);
 extern void tcp_send_delayed_ack(struct sock *sk);
 
@@ -968,7 +967,7 @@ static inline void tcp_reset_xmit_timer(struct sock *sk, int what, unsigned long
 static inline void tcp_initialize_rcv_mss(struct sock *sk)
 {
        struct tcp_sock *tp = tcp_sk(sk);
-       unsigned int hint = min(tp->advmss, tp->mss_cache_std);
+       unsigned int hint = min_t(unsigned int, tp->advmss, tp->mss_cache);
 
        hint = min(hint, tp->rcv_wnd/2);
        hint = min(hint, TCP_MIN_RCVMSS);
@@ -991,7 +990,7 @@ static __inline__ void tcp_fast_path_on(struct tcp_sock *tp)
 
 static inline void tcp_fast_path_check(struct sock *sk, struct tcp_sock *tp)
 {
-       if (skb_queue_len(&tp->out_of_order_queue) == 0 &&
+       if (skb_queue_empty(&tp->out_of_order_queue) &&
            tp->rcv_wnd &&
            atomic_read(&sk->sk_rmem_alloc) < sk->sk_rcvbuf &&
            !tp->urg_data)
@@ -1235,7 +1234,7 @@ static inline void tcp_sync_left_out(struct tcp_sock *tp)
        tp->left_out = tp->sacked_out + tp->lost_out;
 }
 
-/* Set slow start threshould and cwnd not falling to slow start */
+/* Set slow start threshold and cwnd not falling to slow start */
 static inline void __tcp_enter_cwr(struct tcp_sock *tp)
 {
        tp->undo_marker = 0;
@@ -1657,15 +1656,6 @@ static inline int tcp_paws_check(const struct tcp_options_received *rx_opt, int
        return 1;
 }
 
-static inline void tcp_v4_setup_caps(struct sock *sk, struct dst_entry *dst)
-{
-       sk->sk_route_caps = dst->dev->features;
-       if (sk->sk_route_caps & NETIF_F_TSO) {
-               if (sock_flag(sk, SOCK_NO_LARGESEND) || dst->header_len)
-                       sk->sk_route_caps &= ~NETIF_F_TSO;
-       }
-}
-
 #define TCP_CHECK_TIMER(sk) do { } while (0)
 
 static inline int tcp_use_frto(const struct sock *sk)
This page took 0.037605 seconds and 5 git commands to generate.