[INET]: Generalise tcp_tw_bucket, aka TIME_WAIT sockets
[deliverable/linux.git] / include / linux / tcp.h
index b88fe05fdcbf688d82b09b6f25aaef7361136398..5d295b1b3de7d2c82c1053e9e5d73954f395914e 100644 (file)
@@ -179,6 +179,7 @@ struct tcp_info
 #include <linux/skbuff.h>
 #include <linux/ip.h>
 #include <net/sock.h>
+#include <net/inet_timewait_sock.h>
 
 /* This defines a selective acknowledgement block. */
 struct tcp_sack_block {
@@ -387,6 +388,20 @@ static inline struct tcp_sock *tcp_sk(const struct sock *sk)
        return (struct tcp_sock *)sk;
 }
 
+struct tcp_timewait_sock {
+       struct inet_timewait_sock tw_sk;
+       __u32                     tw_rcv_nxt;
+       __u32                     tw_snd_nxt;
+       __u32                     tw_rcv_wnd;
+       __u32                     tw_ts_recent;
+       long                      tw_ts_recent_stamp;
+};
+
+static inline struct tcp_timewait_sock *tcp_twsk(const struct sock *sk)
+{
+       return (struct tcp_timewait_sock *)sk;
+}
+
 static inline void *tcp_ca(const struct tcp_sock *tp)
 {
        return (void *) tp->ca_priv;
This page took 0.024642 seconds and 5 git commands to generate.