aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/net/mac80211.h5
-rw-r--r--net/mac80211/ieee80211.c3
2 files changed, 7 insertions, 1 deletions
diff --git a/include/net/mac80211.h b/include/net/mac80211.h
index 5fcc4c104340..f13c378fde91 100644
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -706,11 +706,16 @@ enum ieee80211_hw_flags {
706 * 706 *
707 * @queues: number of available hardware transmit queues for 707 * @queues: number of available hardware transmit queues for
708 * data packets. WMM/QoS requires at least four. 708 * data packets. WMM/QoS requires at least four.
709 *
710 * @rate_control_algorithm: rate control algorithm for this hardware.
711 * If unset (NULL), the default algorithm will be used. Must be
712 * set before calling ieee80211_register_hw().
709 */ 713 */
710struct ieee80211_hw { 714struct ieee80211_hw {
711 struct ieee80211_conf conf; 715 struct ieee80211_conf conf;
712 struct wiphy *wiphy; 716 struct wiphy *wiphy;
713 struct workqueue_struct *workqueue; 717 struct workqueue_struct *workqueue;
718 const char *rate_control_algorithm;
714 void *priv; 719 void *priv;
715 u32 flags; 720 u32 flags;
716 unsigned int extra_tx_headroom; 721 unsigned int extra_tx_headroom;
diff --git a/net/mac80211/ieee80211.c b/net/mac80211/ieee80211.c
index 52ba6ef90685..e0ee65a969bc 100644
--- a/net/mac80211/ieee80211.c
+++ b/net/mac80211/ieee80211.c
@@ -1072,7 +1072,8 @@ int ieee80211_register_hw(struct ieee80211_hw *hw)
1072 ieee80211_debugfs_add_netdev(IEEE80211_DEV_TO_SUB_IF(local->mdev)); 1072 ieee80211_debugfs_add_netdev(IEEE80211_DEV_TO_SUB_IF(local->mdev));
1073 ieee80211_if_set_type(local->mdev, IEEE80211_IF_TYPE_AP); 1073 ieee80211_if_set_type(local->mdev, IEEE80211_IF_TYPE_AP);
1074 1074
1075 result = ieee80211_init_rate_ctrl_alg(local, NULL); 1075 result = ieee80211_init_rate_ctrl_alg(local,
1076 hw->rate_control_algorithm);
1076 if (result < 0) { 1077 if (result < 0) {
1077 printk(KERN_DEBUG "%s: Failed to initialize rate control " 1078 printk(KERN_DEBUG "%s: Failed to initialize rate control "
1078 "algorithm\n", wiphy_name(local->hw.wiphy)); 1079 "algorithm\n", wiphy_name(local->hw.wiphy));