2011-01-24 03:45:02

by Larry Finger

[permalink] [raw]
Subject: Question about rate control

I'm trying to use a special rate-control algorithm. ATM, this is necessary
because I don't know how to get the retry info from the firmware. This setup
worked fine with rtl8192ce using a fixed name compiled in the rate_control_ops
struct. The problem is that this code is also used by a new USB driver named
rtl8192cu that shares the rtlwifi module with the PCIe driver. When both are
loaded, the second gets a duplicate name warhing. To fix this, I have set up
code that generates a unique name, but it doesn't work. To help debug, I added a
printk to dump the name used in every call to ieee80211_rate_control_register().
The result of that printk is shown below. The 3rd value listed is my new one and
all looks OK; however, the selected rate control is "minstrel_ht", not my
special one.

ops->name: minstrel
ops->name: minstrel_ht
--snip--
ops->name: rtl-rc-0
ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'

Any thoughts on what might be wrong, or what values should be dumped for debugging?

Thanks,

Larry


2011-01-24 05:42:45

by Larry Finger

[permalink] [raw]
Subject: Re: Question about rate control

On 01/23/2011 09:45 PM, Larry Finger wrote:
> I'm trying to use a special rate-control algorithm. ATM, this is necessary
> because I don't know how to get the retry info from the firmware. This setup
> worked fine with rtl8192ce using a fixed name compiled in the rate_control_ops
> struct. The problem is that this code is also used by a new USB driver named
> rtl8192cu that shares the rtlwifi module with the PCIe driver. When both are
> loaded, the second gets a duplicate name warhing. To fix this, I have set up
> code that generates a unique name, but it doesn't work. To help debug, I added a
> printk to dump the name used in every call to ieee80211_rate_control_register().
> The result of that printk is shown below. The 3rd value listed is my new one and
> all looks OK; however, the selected rate control is "minstrel_ht", not my
> special one.
>
> ops->name: minstrel
> ops->name: minstrel_ht
> --snip--
> ops->name: rtl-rc-0
> ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
>
> Any thoughts on what might be wrong, or what values should be dumped for debugging?

I figured out my problem - I was not setting the rate_control_algorithm entry in
struct ieee80211_hw correctly. All is fine now.

Larry