Commit f982307f authored by Joe Eykholt's avatar Joe Eykholt Committed by Jeff Garzik

net/core: Allow receive on active slaves.

If a packet_type specifies an active slave to bonding and not just any
interface, allow it to receive frames that came in on that interface.
Signed-off-by: default avatarJoe Eykholt <jre@nuovasystems.com>
Signed-off-by: default avatarJay Vosburgh <fubar@us.ibm.com>
Signed-off-by: default avatarJeff Garzik <jgarzik@redhat.com>
parent 0d7a3681
...@@ -2210,7 +2210,8 @@ int netif_receive_skb(struct sk_buff *skb) ...@@ -2210,7 +2210,8 @@ int netif_receive_skb(struct sk_buff *skb)
#endif #endif
list_for_each_entry_rcu(ptype, &ptype_all, list) { list_for_each_entry_rcu(ptype, &ptype_all, list) {
if (ptype->dev == null_or_orig || ptype->dev == skb->dev) { if (ptype->dev == null_or_orig || ptype->dev == skb->dev ||
ptype->dev == orig_dev) {
if (pt_prev) if (pt_prev)
ret = deliver_skb(skb, pt_prev, orig_dev); ret = deliver_skb(skb, pt_prev, orig_dev);
pt_prev = ptype; pt_prev = ptype;
...@@ -2235,7 +2236,8 @@ int netif_receive_skb(struct sk_buff *skb) ...@@ -2235,7 +2236,8 @@ int netif_receive_skb(struct sk_buff *skb)
list_for_each_entry_rcu(ptype, list_for_each_entry_rcu(ptype,
&ptype_base[ntohs(type) & PTYPE_HASH_MASK], list) { &ptype_base[ntohs(type) & PTYPE_HASH_MASK], list) {
if (ptype->type == type && if (ptype->type == type &&
(ptype->dev == null_or_orig || ptype->dev == skb->dev)) { (ptype->dev == null_or_orig || ptype->dev == skb->dev ||
ptype->dev == orig_dev)) {
if (pt_prev) if (pt_prev)
ret = deliver_skb(skb, pt_prev, orig_dev); ret = deliver_skb(skb, pt_prev, orig_dev);
pt_prev = ptype; pt_prev = ptype;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment