mac80211: make simple rate control algorithm built-in
Too frequently people do not have module autoloading enabled or fail to install the rate control module correctly, hence their hardware probing fails due to no rate control algorithm being available. This makes the 'simple' algorithm built into the mac80211 module unless EMBEDDED is enabled in which case it can be disabled (eg. if the wanted driver requires another rate control algorithm.) Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Acked-by: Michael Buesch <mb@bu3sch.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:

committed by
David S. Miller

parent
8a8f1c0437
commit
ac71c691e6
@@ -1233,8 +1233,17 @@ static int __init ieee80211_init(void)
|
||||
|
||||
BUILD_BUG_ON(sizeof(struct ieee80211_tx_packet_data) > sizeof(skb->cb));
|
||||
|
||||
#ifdef CONFIG_MAC80211_RCSIMPLE
|
||||
ret = ieee80211_rate_control_register(&mac80211_rcsimple);
|
||||
if (ret)
|
||||
return ret;
|
||||
#endif
|
||||
|
||||
ret = ieee80211_wme_register();
|
||||
if (ret) {
|
||||
#ifdef CONFIG_MAC80211_RCSIMPLE
|
||||
ieee80211_rate_control_unregister(&mac80211_rcsimple);
|
||||
#endif
|
||||
printk(KERN_DEBUG "ieee80211_init: failed to "
|
||||
"initialize WME (err=%d)\n", ret);
|
||||
return ret;
|
||||
@@ -1248,6 +1257,10 @@ static int __init ieee80211_init(void)
|
||||
|
||||
static void __exit ieee80211_exit(void)
|
||||
{
|
||||
#ifdef CONFIG_MAC80211_RCSIMPLE
|
||||
ieee80211_rate_control_unregister(&mac80211_rcsimple);
|
||||
#endif
|
||||
|
||||
ieee80211_wme_unregister();
|
||||
ieee80211_debugfs_netdev_exit();
|
||||
}
|
||||
|
Reference in New Issue
Block a user