summaryrefslogtreecommitdiffstats
path: root/net/mac802154/monitor.c
diff options
context:
space:
mode:
authorPhoebe Buckheister <phoebe.buckheister@itwm.fraunhofer.de>2014-06-11 12:03:07 +0200
committerDavid S. Miller <davem@davemloft.net>2014-06-11 12:10:19 -0700
commit2d3b5b0a90e5370ad13ca98d95519c3e41d2c925 (patch)
treebad4e444da804759fe1d8f91d4a940cdcb4ca1fb /net/mac802154/monitor.c
parenta374eeb5e5b35c877a890dce5d3f7cca5a3e33f6 (diff)
downloadop-kernel-dev-2d3b5b0a90e5370ad13ca98d95519c3e41d2c925.zip
op-kernel-dev-2d3b5b0a90e5370ad13ca98d95519c3e41d2c925.tar.gz
mac802154: don't deliver packets to devices that are down
Only one WPAN devices can be active at any given time, so only deliver packets to that one interface that is actually up. Multiple monitors may be up at any given time, but we don't have to deliver to monitors that are down either. Signed-off-by: Phoebe Buckheister <phoebe.buckheister@itwm.fraunhofer.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/mac802154/monitor.c')
-rw-r--r--net/mac802154/monitor.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/mac802154/monitor.c b/net/mac802154/monitor.c
index 434a26f..a68230e 100644
--- a/net/mac802154/monitor.c
+++ b/net/mac802154/monitor.c
@@ -70,7 +70,8 @@ void mac802154_monitors_rx(struct mac802154_priv *priv, struct sk_buff *skb)
rcu_read_lock();
list_for_each_entry_rcu(sdata, &priv->slaves, list) {
- if (sdata->type != IEEE802154_DEV_MONITOR)
+ if (sdata->type != IEEE802154_DEV_MONITOR ||
+ !netif_running(sdata->dev))
continue;
skb2 = skb_clone(skb, GFP_ATOMIC);
OpenPOWER on IntegriCloud