diff options
Diffstat (limited to 'include/linux/tcp.h')
-rw-r--r-- | include/linux/tcp.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/linux/tcp.h b/include/linux/tcp.h index 60b7aac15e0e..4e1d2283e3cc 100644 --- a/include/linux/tcp.h +++ b/include/linux/tcp.h | |||
@@ -35,6 +35,16 @@ static inline unsigned int tcp_hdrlen(const struct sk_buff *skb) | |||
35 | return tcp_hdr(skb)->doff * 4; | 35 | return tcp_hdr(skb)->doff * 4; |
36 | } | 36 | } |
37 | 37 | ||
38 | static inline struct tcphdr *inner_tcp_hdr(const struct sk_buff *skb) | ||
39 | { | ||
40 | return (struct tcphdr *)skb_inner_transport_header(skb); | ||
41 | } | ||
42 | |||
43 | static inline unsigned int inner_tcp_hdrlen(const struct sk_buff *skb) | ||
44 | { | ||
45 | return inner_tcp_hdr(skb)->doff * 4; | ||
46 | } | ||
47 | |||
38 | static inline unsigned int tcp_optlen(const struct sk_buff *skb) | 48 | static inline unsigned int tcp_optlen(const struct sk_buff *skb) |
39 | { | 49 | { |
40 | return (tcp_hdr(skb)->doff - 5) * 4; | 50 | return (tcp_hdr(skb)->doff - 5) * 4; |