path: root/drivers/staging/winbond
diff options
authorJohannes Berg <johannes.berg@intel.com>2011-02-24 14:42:06 +0100
committerJohn W. Linville <linville@tuxdriver.com>2011-02-25 15:32:34 -0500
commit7bb4568372856688bc070917265bce0b88bb7d4d (patch)
treee3ca3e7d233944bbc271c650c8b037c3a6652d98 /drivers/staging/winbond
parent43f12d47f0580e04e26c14c03cb19cea9687854e (diff)
mac80211: make tx() operation return void
The return value of the tx operation is commonly misused by drivers, leading to errors. All drivers will drop frames if they fail to TX the frame, and they must also properly manage the queues (if they didn't, mac80211 would already warn). Removing the ability for drivers to return a BUSY value also allows significant cleanups of the TX TX handling code in mac80211. Note that this also fixes a bug in ath9k_htc, the old "return -1" there was wrong. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Tested-by: Sedat Dilek <sedat.dilek@googlemail.com> [ath5k] Acked-by: Gertjan van Wingerde <gwingerde@gmail.com> [rt2x00] Acked-by: Larry Finger <Larry.Finger@lwfinger.net> [b43, rtl8187, rtlwifi] Acked-by: Luciano Coelho <coelho@ti.com> [wl12xx] Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/staging/winbond')
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/staging/winbond/wbusb.c b/drivers/staging/winbond/wbusb.c
index 2163d60c2ea..3724e1e67ec 100644
--- a/drivers/staging/winbond/wbusb.c
+++ b/drivers/staging/winbond/wbusb.c
@@ -118,13 +118,14 @@ static void wbsoft_configure_filter(struct ieee80211_hw *dev,
*total_flags = new_flags;
-static int wbsoft_tx(struct ieee80211_hw *dev, struct sk_buff *skb)
+static void wbsoft_tx(struct ieee80211_hw *dev, struct sk_buff *skb)
struct wbsoft_priv *priv = dev->priv;
if (priv->sMlmeFrame.IsInUsed != PACKET_FREE_TO_USE) {
- return NETDEV_TX_BUSY;
+ kfree_skb(skb);
+ return;
priv->sMlmeFrame.IsInUsed = PACKET_COME_FROM_MLME;
@@ -140,8 +141,6 @@ static int wbsoft_tx(struct ieee80211_hw *dev, struct sk_buff *skb)
- return NETDEV_TX_OK;
static int wbsoft_start(struct ieee80211_hw *dev)