struct dst_entry *(*route_req)(struct sock *sk, struct flowi *fl,
const struct request_sock *req,
bool *strict);
+ __u32 (*init_seq)(const struct sk_buff *skb);
};
#ifdef CONFIG_SYN_COOKIES
struct inet_hashinfo tcp_hashinfo;
EXPORT_SYMBOL(tcp_hashinfo);
-static inline __u32 tcp_v4_init_sequence(const struct sk_buff *skb)
+static __u32 tcp_v4_init_sequence(const struct sk_buff *skb)
{
return secure_tcp_sequence_number(ip_hdr(skb)->daddr,
ip_hdr(skb)->saddr,
.cookie_init_seq = cookie_v4_init_sequence,
#endif
.route_req = tcp_v4_route_req,
+ .init_seq = tcp_v4_init_sequence,
};
int tcp_v4_conn_request(struct sock *sk, struct sk_buff *skb)
goto drop_and_release;
}
- isn = tcp_v4_init_sequence(skb);
+ isn = af_ops->init_seq(skb);
}
if (!dst) {
dst = af_ops->route_req(sk, (struct flowi *)&fl4, req, NULL);
.cookie_init_seq = cookie_v6_init_sequence,
#endif
.route_req = tcp_v6_route_req,
+ .init_seq = tcp_v6_init_sequence,
};
static void tcp_v6_send_response(struct sk_buff *skb, u32 seq, u32 ack, u32 win,
goto drop_and_release;
}
- isn = tcp_v6_init_sequence(skb);
+ isn = af_ops->init_seq(skb);
}
if (!dst) {