summaryrefslogtreecommitdiffstats
path: root/net/mac80211/ieee80211.c
diff options
context:
space:
mode:
authorIvo van Doorn <ivdoorn@gmail.com>2008-01-07 19:45:24 +0100
committerDavid S. Miller <davem@davemloft.net>2008-01-29 00:01:04 +0100
commitcdcb006fbe7a74b5f7827f5c5c27e11399a2fab7 (patch)
tree6141a5b4315775bea971d3457191071d36061822 /net/mac80211/ieee80211.c
parentrc80211_pid should respect fixed rates. (diff)
downloadlinux-cdcb006fbe7a74b5f7827f5c5c27e11399a2fab7.tar.xz
linux-cdcb006fbe7a74b5f7827f5c5c27e11399a2fab7.zip
mac80211: Add radio led trigger
Some devices have a seperate LED which indicates if the radio is enabled or not. This adds a LED trigger to mac80211 where drivers can hook into when they are interested in radio status changes. v2: Check hw.conf.radio_enabled when calling start(). Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/mac80211/ieee80211.c')
-rw-r--r--net/mac80211/ieee80211.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/net/mac80211/ieee80211.c b/net/mac80211/ieee80211.c
index 8ba69ae676ca..4807e5215a79 100644
--- a/net/mac80211/ieee80211.c
+++ b/net/mac80211/ieee80211.c
@@ -219,6 +219,7 @@ static int ieee80211_open(struct net_device *dev)
if (res)
return res;
ieee80211_hw_config(local);
+ ieee80211_led_radio(local, local->hw.conf.radio_enabled);
}
switch (sdata->type) {
@@ -392,6 +393,8 @@ static int ieee80211_stop(struct net_device *dev)
if (local->ops->stop)
local->ops->stop(local_to_hw(local));
+ ieee80211_led_radio(local, 0);
+
tasklet_disable(&local->tx_pending_tasklet);
tasklet_disable(&local->tasklet);
}