p54: implement FIF_OTHER_BSS filter setting
authorChristian Lamparter <chunkeey@web.de>
Tue, 30 Dec 2008 12:48:29 +0000 (13:48 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Thu, 29 Jan 2009 20:59:44 +0000 (15:59 -0500)
According to STMicroelectronics' LMAC documentation, the P54_FILTER_TYPE_TRANSPARENT flag
"configures the receive frame filter to pass all frames without regard to type and address matching."

Signed-off-by: Christian Lamparter <chunkeey@web.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/p54/p54common.c

index 6e9f73745b6859fd671b131c9e52abcf119c34b6..d85a6bafd79f3a9639bf4dacc50956b67424560e 100644 (file)
@@ -1579,7 +1579,8 @@ static int p54_setup_mac(struct ieee80211_hw *dev)
                 * "TRANSPARENT and PROMISCUOUS are mutually exclusive"
                 * STSW45X0C LMAC API - page 12
                 */
-               if ((priv->filter_flags & FIF_PROMISC_IN_BSS) &&
+               if (((priv->filter_flags & FIF_PROMISC_IN_BSS) ||
+                    (priv->filter_flags & FIF_OTHER_BSS)) &&
                    (mode != P54_FILTER_TYPE_PROMISCUOUS))
                        mode |= P54_FILTER_TYPE_TRANSPARENT;
        } else
@@ -2007,12 +2008,13 @@ static void p54_configure_filter(struct ieee80211_hw *dev,
        struct p54_common *priv = dev->priv;
 
        *total_flags &= FIF_PROMISC_IN_BSS |
+                       FIF_OTHER_BSS |
                        (*total_flags & FIF_PROMISC_IN_BSS) ?
                                FIF_FCSFAIL : 0;
 
        priv->filter_flags = *total_flags;
 
-       if (changed_flags & FIF_PROMISC_IN_BSS)
+       if (changed_flags & (FIF_PROMISC_IN_BSS | FIF_OTHER_BSS))
                p54_setup_mac(dev);
 }