diff options
Diffstat (limited to 'include/linux/skbuff.h')
-rw-r--r-- | include/linux/skbuff.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index 320e976d5ab8..8b2256e880e0 100644 --- a/include/linux/skbuff.h +++ b/include/linux/skbuff.h | |||
@@ -1492,6 +1492,11 @@ static inline void skb_set_inner_network_header(struct sk_buff *skb, | |||
1492 | skb->inner_network_header += offset; | 1492 | skb->inner_network_header += offset; |
1493 | } | 1493 | } |
1494 | 1494 | ||
1495 | static inline bool skb_transport_header_was_set(const struct sk_buff *skb) | ||
1496 | { | ||
1497 | return skb->transport_header != ~0U; | ||
1498 | } | ||
1499 | |||
1495 | static inline unsigned char *skb_transport_header(const struct sk_buff *skb) | 1500 | static inline unsigned char *skb_transport_header(const struct sk_buff *skb) |
1496 | { | 1501 | { |
1497 | return skb->head + skb->transport_header; | 1502 | return skb->head + skb->transport_header; |
@@ -1580,6 +1585,11 @@ static inline void skb_set_inner_network_header(struct sk_buff *skb, | |||
1580 | skb->inner_network_header = skb->data + offset; | 1585 | skb->inner_network_header = skb->data + offset; |
1581 | } | 1586 | } |
1582 | 1587 | ||
1588 | static inline bool skb_transport_header_was_set(const struct sk_buff *skb) | ||
1589 | { | ||
1590 | return skb->transport_header != NULL; | ||
1591 | } | ||
1592 | |||
1583 | static inline unsigned char *skb_transport_header(const struct sk_buff *skb) | 1593 | static inline unsigned char *skb_transport_header(const struct sk_buff *skb) |
1584 | { | 1594 | { |
1585 | return skb->transport_header; | 1595 | return skb->transport_header; |