summaryrefslogtreecommitdiffstats
path: root/include/net/ip.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/net/ip.h')
-rw-r--r--include/net/ip.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/include/net/ip.h b/include/net/ip.h
index e79c3e3aa4f..6f7ba32b199 100644
--- a/include/net/ip.h
+++ b/include/net/ip.h
@@ -25,6 +25,7 @@
#include <linux/types.h>
#include <linux/ip.h>
#include <linux/in.h>
+#include <linux/skbuff.h>
#include <net/inet_sock.h>
#include <net/snmp.h>
@@ -43,6 +44,11 @@ struct inet_skb_parm
#define IPSKB_REROUTED 16
};
+static inline unsigned int ip_hdrlen(const struct sk_buff *skb)
+{
+ return skb->nh.iph->ihl * 4;
+}
+
struct ipcm_cookie
{
__be32 addr;
@@ -74,7 +80,6 @@ struct msghdr;
struct net_device;
struct packet_type;
struct rtable;
-struct sk_buff;
struct sockaddr;
extern void ip_mc_dropsocket(struct sock *);