www.usr.com/support/gpl/USR9107_release.1.4.tar.gz
[bcm963xx.git] / kernel / linux / net / bridge / br_forward.c
index 102dbe1..d986fef 100755 (executable)
@@ -34,7 +34,7 @@ static inline int should_deliver(const struct net_bridge_port *p,
         * add the check to compare the first 3 chars from the name as
         * shown below. Using strcmp will be expensive in this path.
        */
-       if ((skb->rcvfrom == FROM_WAN)  &&
+       if ((skb->nfmark & FROM_WAN)  &&
            ((*(p->dev->name)    == 'n') &&
            (*(p->dev->name + 1) == 'a') &&
            (*(p->dev->name + 2) == 's')))
@@ -46,6 +46,16 @@ static inline int should_deliver(const struct net_bridge_port *p,
 
 int br_dev_queue_push_xmit(struct sk_buff *skb)
 {
+#if defined(CONFIG_MIPS_BRCM)
+       // Just to make it consistent with 2.4 so it will not surprise the customers.(Should be more intelligent.)
+#ifdef CONFIG_BRIDGE_NETFILTER
+       /* ip_refrag calls ip_fragment, doesn't copy the MAC header. */
+       nf_bridge_maybe_copy_header(skb);
+#endif
+       skb_push(skb, ETH_HLEN);
+
+       dev_queue_xmit(skb);
+#else
        if (skb->len > skb->dev->mtu) 
                kfree_skb(skb);
        else {
@@ -57,6 +67,7 @@ int br_dev_queue_push_xmit(struct sk_buff *skb)
 
                dev_queue_xmit(skb);
        }
+#endif
 
        return 0;
 }