]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - net/core/filter.c
Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6
[linux-2.6-omap-h63xx.git] / net / core / filter.c
index 8123a31d919daacfd8b782a5f3e9401e7fa08e7d..bd903aaf7aa74fb871f4f4cdda14c6cd55755ee5 100644 (file)
@@ -18,7 +18,6 @@
 
 #include <linux/module.h>
 #include <linux/types.h>
-#include <linux/sched.h>
 #include <linux/mm.h>
 #include <linux/fcntl.h>
 #include <linux/socket.h>
@@ -43,11 +42,11 @@ static void *__load_pointer(struct sk_buff *skb, int k)
        u8 *ptr = NULL;
 
        if (k >= SKF_NET_OFF)
-               ptr = skb->nh.raw + k - SKF_NET_OFF;
+               ptr = skb_network_header(skb) + k - SKF_NET_OFF;
        else if (k >= SKF_LL_OFF)
-               ptr = skb->mac.raw + k - SKF_LL_OFF;
+               ptr = skb_mac_header(skb) + k - SKF_LL_OFF;
 
-       if (ptr >= skb->head && ptr < skb->tail)
+       if (ptr >= skb->head && ptr < skb_tail_pointer(skb))
                return ptr;
        return NULL;
 }