aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2012-07-02 09:40:18 -0400
committerJohannes Berg <johannes.berg@intel.com>2012-07-02 09:40:18 -0400
commitcb831b537d50d21f6afb5dffbde4cf6523627461 (patch)
tree7d9b48f51264335f8338d786cbe211bda320a92e
parentba0afa2f22e1e3f332e45460f99328025d44564e (diff)
mac80211: remove tx_frags driver callback
The implementation of tx_frags is buggy due to not handling queue stop, and there's no driver implementing it so remove it. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
-rw-r--r--include/net/mac80211.h15
-rw-r--r--net/mac80211/driver-ops.h8
-rw-r--r--net/mac80211/main.c2
-rw-r--r--net/mac80211/tx.c7
4 files changed, 3 insertions, 29 deletions
diff --git a/include/net/mac80211.h b/include/net/mac80211.h
index b5da094468f1..dc2a97af95e7 100644
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -1896,19 +1896,6 @@ enum ieee80211_rate_control_changed {
1896 * The low-level driver should send the frame out based on 1896 * The low-level driver should send the frame out based on
1897 * configuration in the TX control data. This handler should, 1897 * configuration in the TX control data. This handler should,
1898 * preferably, never fail and stop queues appropriately. 1898 * preferably, never fail and stop queues appropriately.
1899 * This must be implemented if @tx_frags is not.
1900 * Must be atomic.
1901 *
1902 * @tx_frags: Called to transmit multiple fragments of a single MSDU.
1903 * This handler must consume all fragments, sending out some of
1904 * them only is useless and it can't ask for some of them to be
1905 * queued again. If the frame is not fragmented the queue has a
1906 * single SKB only. To avoid issues with the networking stack
1907 * when TX status is reported the frames should be removed from
1908 * the skb queue.
1909 * If this is used, the tx_info @vif and @sta pointers will be
1910 * invalid -- you must not use them in that case.
1911 * This must be implemented if @tx isn't.
1912 * Must be atomic. 1899 * Must be atomic.
1913 * 1900 *
1914 * @start: Called before the first netdevice attached to the hardware 1901 * @start: Called before the first netdevice attached to the hardware
@@ -2260,8 +2247,6 @@ enum ieee80211_rate_control_changed {
2260 */ 2247 */
2261struct ieee80211_ops { 2248struct ieee80211_ops {
2262 void (*tx)(struct ieee80211_hw *hw, struct sk_buff *skb); 2249 void (*tx)(struct ieee80211_hw *hw, struct sk_buff *skb);
2263 void (*tx_frags)(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
2264 struct ieee80211_sta *sta, struct sk_buff_head *skbs);
2265 int (*start)(struct ieee80211_hw *hw); 2250 int (*start)(struct ieee80211_hw *hw);
2266 void (*stop)(struct ieee80211_hw *hw); 2251 void (*stop)(struct ieee80211_hw *hw);
2267#ifdef CONFIG_PM 2252#ifdef CONFIG_PM
diff --git a/net/mac80211/driver-ops.h b/net/mac80211/driver-ops.h
index 44e8c1242781..5042151a3325 100644
--- a/net/mac80211/driver-ops.h
+++ b/net/mac80211/driver-ops.h
@@ -27,14 +27,6 @@ static inline void drv_tx(struct ieee80211_local *local, struct sk_buff *skb)
27 local->ops->tx(&local->hw, skb); 27 local->ops->tx(&local->hw, skb);
28} 28}
29 29
30static inline void drv_tx_frags(struct ieee80211_local *local,
31 struct ieee80211_vif *vif,
32 struct ieee80211_sta *sta,
33 struct sk_buff_head *skbs)
34{
35 local->ops->tx_frags(&local->hw, vif, sta, skbs);
36}
37
38static inline void drv_get_et_strings(struct ieee80211_sub_if_data *sdata, 30static inline void drv_get_et_strings(struct ieee80211_sub_if_data *sdata,
39 u32 sset, u8 *data) 31 u32 sset, u8 *data)
40{ 32{
diff --git a/net/mac80211/main.c b/net/mac80211/main.c
index ab32c59be894..c794101f8987 100644
--- a/net/mac80211/main.c
+++ b/net/mac80211/main.c
@@ -587,7 +587,7 @@ struct ieee80211_hw *ieee80211_alloc_hw(size_t priv_data_len,
587 587
588 local->hw.priv = (char *)local + ALIGN(sizeof(*local), NETDEV_ALIGN); 588 local->hw.priv = (char *)local + ALIGN(sizeof(*local), NETDEV_ALIGN);
589 589
590 BUG_ON(!ops->tx && !ops->tx_frags); 590 BUG_ON(!ops->tx);
591 BUG_ON(!ops->start); 591 BUG_ON(!ops->start);
592 BUG_ON(!ops->stop); 592 BUG_ON(!ops->stop);
593 BUG_ON(!ops->config); 593 BUG_ON(!ops->config);
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
index 4990f4fb5864..364a1e7b4afa 100644
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -1295,11 +1295,8 @@ static bool __ieee80211_tx(struct ieee80211_local *local,
1295 break; 1295 break;
1296 } 1296 }
1297 1297
1298 if (local->ops->tx_frags) 1298 result = ieee80211_tx_frags(local, vif, pubsta, skbs,
1299 drv_tx_frags(local, vif, pubsta, skbs); 1299 txpending);
1300 else
1301 result = ieee80211_tx_frags(local, vif, pubsta, skbs,
1302 txpending);
1303 1300
1304 ieee80211_tpt_led_trig_tx(local, fc, led_len); 1301 ieee80211_tpt_led_trig_tx(local, fc, led_len);
1305 ieee80211_led_tx(local, 1); 1302 ieee80211_led_tx(local, 1);