aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/at76c50x-usb.c
diff options
context:
space:
mode:
authorJohannes Berg <johannes@sipsolutions.net>2009-08-17 10:16:53 -0400
committerJohn W. Linville <linville@tuxdriver.com>2009-08-20 11:35:58 -0400
commit3ac64beecd27400d12cc7afb4108eef26c499f6a (patch)
treeda0220085f68e30fe61ba9b8833dc6311d6dc25e /drivers/net/wireless/at76c50x-usb.c
parentea416a793d2b611f22b42ba094fd2e5bd30fff43 (diff)
mac80211: allow configure_filter callback to sleep
Over time, a whole bunch of drivers have come up with their own scheme to delay the configure_filter operation to a workqueue. To be able to simplify things, allow configure_filter to sleep, and add a new prepare_multicast callback that drivers that need the multicast address list implement. This new callback must be atomic, but most drivers either don't care or just calculate a hash which can be done atomically and then uploaded to the hardware non-atomically. A cursory look suggests that at76c50x-usb, ar9170, mwl8k (which is actually very broken now), rt2x00, wl1251, wl1271 and zd1211 should make use of this new capability. Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/at76c50x-usb.c')
-rw-r--r--drivers/net/wireless/at76c50x-usb.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/net/wireless/at76c50x-usb.c b/drivers/net/wireless/at76c50x-usb.c
index 7218dbabad3e..a6e19545ac6a 100644
--- a/drivers/net/wireless/at76c50x-usb.c
+++ b/drivers/net/wireless/at76c50x-usb.c
@@ -1997,15 +1997,14 @@ static void at76_bss_info_changed(struct ieee80211_hw *hw,
1997/* must be atomic */ 1997/* must be atomic */
1998static void at76_configure_filter(struct ieee80211_hw *hw, 1998static void at76_configure_filter(struct ieee80211_hw *hw,
1999 unsigned int changed_flags, 1999 unsigned int changed_flags,
2000 unsigned int *total_flags, int mc_count, 2000 unsigned int *total_flags, u64 multicast)
2001 struct dev_addr_list *mc_list)
2002{ 2001{
2003 struct at76_priv *priv = hw->priv; 2002 struct at76_priv *priv = hw->priv;
2004 int flags; 2003 int flags;
2005 2004
2006 at76_dbg(DBG_MAC80211, "%s(): changed_flags=0x%08x " 2005 at76_dbg(DBG_MAC80211, "%s(): changed_flags=0x%08x "
2007 "total_flags=0x%08x mc_count=%d", 2006 "total_flags=0x%08x",
2008 __func__, changed_flags, *total_flags, mc_count); 2007 __func__, changed_flags, *total_flags);
2009 2008
2010 flags = changed_flags & AT76_SUPPORTED_FILTERS; 2009 flags = changed_flags & AT76_SUPPORTED_FILTERS;
2011 *total_flags = AT76_SUPPORTED_FILTERS; 2010 *total_flags = AT76_SUPPORTED_FILTERS;