diff options
Diffstat (limited to 'net/bridge')
-rw-r--r-- | net/bridge/br_device.c | 2 | ||||
-rw-r--r-- | net/bridge/br_input.c | 2 | ||||
-rw-r--r-- | net/bridge/br_private.h | 8 |
3 files changed, 10 insertions, 2 deletions
diff --git a/net/bridge/br_device.c b/net/bridge/br_device.c index eb7062d2e9e5..90a9024e5c1e 100644 --- a/net/bridge/br_device.c +++ b/net/bridge/br_device.c | |||
@@ -40,7 +40,7 @@ netdev_tx_t br_dev_xmit(struct sk_buff *skb, struct net_device *dev) | |||
40 | goto out; | 40 | goto out; |
41 | 41 | ||
42 | mdst = br_mdb_get(br, skb); | 42 | mdst = br_mdb_get(br, skb); |
43 | if (mdst || BR_INPUT_SKB_CB(skb)->mrouters_only) | 43 | if (mdst || BR_INPUT_SKB_CB_MROUTERS_ONLY(skb)) |
44 | br_multicast_deliver(mdst, skb); | 44 | br_multicast_deliver(mdst, skb); |
45 | else | 45 | else |
46 | br_flood_deliver(br, skb); | 46 | br_flood_deliver(br, skb); |
diff --git a/net/bridge/br_input.c b/net/bridge/br_input.c index 08a72e63fb8e..d74d570fc848 100644 --- a/net/bridge/br_input.c +++ b/net/bridge/br_input.c | |||
@@ -70,7 +70,7 @@ int br_handle_frame_finish(struct sk_buff *skb) | |||
70 | 70 | ||
71 | if (is_multicast_ether_addr(dest)) { | 71 | if (is_multicast_ether_addr(dest)) { |
72 | mdst = br_mdb_get(br, skb); | 72 | mdst = br_mdb_get(br, skb); |
73 | if (mdst || BR_INPUT_SKB_CB(skb)->mrouters_only) { | 73 | if (mdst || BR_INPUT_SKB_CB_MROUTERS_ONLY(skb)) { |
74 | if ((mdst && !hlist_unhashed(&mdst->mglist)) || | 74 | if ((mdst && !hlist_unhashed(&mdst->mglist)) || |
75 | br_multicast_is_router(br)) | 75 | br_multicast_is_router(br)) |
76 | skb2 = skb; | 76 | skb2 = skb; |
diff --git a/net/bridge/br_private.h b/net/bridge/br_private.h index bfb8feb310a6..846d7d1e2075 100644 --- a/net/bridge/br_private.h +++ b/net/bridge/br_private.h | |||
@@ -206,12 +206,20 @@ struct net_bridge | |||
206 | 206 | ||
207 | struct br_input_skb_cb { | 207 | struct br_input_skb_cb { |
208 | struct net_device *brdev; | 208 | struct net_device *brdev; |
209 | #ifdef CONFIG_BRIDGE_IGMP_SNOOPING | ||
209 | int igmp; | 210 | int igmp; |
210 | int mrouters_only; | 211 | int mrouters_only; |
212 | #endif | ||
211 | }; | 213 | }; |
212 | 214 | ||
213 | #define BR_INPUT_SKB_CB(__skb) ((struct br_input_skb_cb *)(__skb)->cb) | 215 | #define BR_INPUT_SKB_CB(__skb) ((struct br_input_skb_cb *)(__skb)->cb) |
214 | 216 | ||
217 | #ifdef CONFIG_BRIDGE_IGMP_SNOOPING | ||
218 | # define BR_INPUT_SKB_CB_MROUTERS_ONLY(__skb) (BR_INPUT_SKB_CB(__skb)->mrouters_only) | ||
219 | #else | ||
220 | # define BR_INPUT_SKB_CB_MROUTERS_ONLY(__skb) (0) | ||
221 | #endif | ||
222 | |||
215 | extern struct notifier_block br_device_notifier; | 223 | extern struct notifier_block br_device_notifier; |
216 | extern const u8 br_group_address[ETH_ALEN]; | 224 | extern const u8 br_group_address[ETH_ALEN]; |
217 | 225 | ||