Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
[linux-drm-fsl-dcu.git] / net / sched / cls_fw.c
index e54acc6bcccdc94445fafd86a22ae85e0b236921..2ce3ce5c66eb097f4738c4a53fa2ddefe6bf91cc 100644 (file)
@@ -91,7 +91,7 @@ static __inline__ int fw_hash(u32 handle)
        else if (HTSIZE == 256) {
                u8 *t = (u8 *) &handle;
                return t[0] ^ t[1] ^ t[2] ^ t[3];
-       } else 
+       } else
                return handle & (HTSIZE - 1);
 }
 
@@ -101,13 +101,10 @@ static int fw_classify(struct sk_buff *skb, struct tcf_proto *tp,
        struct fw_head *head = (struct fw_head*)tp->root;
        struct fw_filter *f;
        int r;
-#ifdef CONFIG_NETFILTER
-       u32 id = skb->nfmark & head->mask;
-#else
-       u32 id = 0;
-#endif
+       u32 id = skb->mark;
 
        if (head != NULL) {
+               id &= head->mask;
                for (f=head->ht[fw_hash(id)]; f; f=f->next) {
                        if (f->id == id) {
                                *res = f->res;
@@ -410,7 +407,7 @@ static int __init init_fw(void)
        return register_tcf_proto_ops(&cls_fw_ops);
 }
 
-static void __exit exit_fw(void) 
+static void __exit exit_fw(void)
 {
        unregister_tcf_proto_ops(&cls_fw_ops);
 }