wl12xx: remove warning message during IBSS Tx
authorShahar Lev <shahar@wizery.com>
Fri, 7 Oct 2011 16:17:25 +0000 (18:17 +0200)
committerLuciano Coelho <coelho@ti.com>
Tue, 11 Oct 2011 16:16:23 +0000 (19:16 +0300)
mac80211 sets the carrier on an IBSS interface even when no network is
joined. Ignore garbage frames transmitted on a disconnected IBSS
interface without printing warnings.

Signed-off-by: Shahar Lev <shahar@wizery.com>
[merged with wlvif changes]
Signed-off-by: Luciano Coelho <coelho@ti.com>
drivers/net/wireless/wl12xx/tx.c

index 5351f015feeff2a21e7115a61b24f124a6c4f15a..27a45e1459c4e00563d5da66a81c967fe7521a79 100644 (file)
@@ -428,7 +428,15 @@ static int wl1271_prepare_tx_frame(struct wl1271 *wl, struct wl12xx_vif *wlvif,
        }
        hlid = wl12xx_tx_get_hlid(wl, wlvif, skb);
        if (hlid == WL12XX_INVALID_LINK_ID) {
-               wl1271_error("invalid hlid. dropping skb 0x%p", skb);
+               if (wlvif->bss_type == BSS_TYPE_IBSS &&
+                   !test_bit(WLVIF_FLAG_IBSS_JOINED, &wlvif->flags)) {
+                       /* It's ok to drop packets when not joined to IBSS */
+                       wl1271_debug(DEBUG_TX, "dropping skb while IBSS not "
+                                    " joined");
+               } else {
+                       wl1271_error("invalid hlid. dropping skb 0x%p", skb);
+               }
+
                return -EINVAL;
        }
 
This page took 0.026056 seconds and 5 git commands to generate.