rt2x00: Invert scheduled packet_filter check
authorIvo van Doorn <ivdoorn@gmail.com>
Sat, 29 Mar 2008 14:59:01 +0000 (15:59 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 1 Apr 2008 21:13:20 +0000 (17:13 -0400)
Invert the check for scheduling the packet_filter configuration.
When DRIVER_REQUIRE_SCHEDULED is not set we should immediately
configure the the filter.

This fixes the 'infinite calls to rt2x00mc_configure_filter'
bug reported by Bas Hulsken.

Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/rt2x00/rt2x00mac.c

index 17b6bb034ebfefbe6f25181c03167fa9f4952437..a0adf5a04aa0f6f553f4343d786e9e80c2ec4e4a 100644 (file)
@@ -418,9 +418,9 @@ void rt2x00mac_configure_filter(struct ieee80211_hw *hw,
        rt2x00dev->packet_filter = *total_flags;
 
        if (!test_bit(DRIVER_REQUIRE_SCHEDULED, &rt2x00dev->flags))
-               queue_work(rt2x00dev->hw->workqueue, &rt2x00dev->filter_work);
-       else
                rt2x00dev->ops->lib->config_filter(rt2x00dev, *total_flags);
+       else
+               queue_work(rt2x00dev->hw->workqueue, &rt2x00dev->filter_work);
 }
 EXPORT_SYMBOL_GPL(rt2x00mac_configure_filter);