On 03/25/2013 01:29 PM, Vincent Brillault wrote:
Hi Larry and everyone else on the list, I've seen your 25 patches and applied them in hope my problems were resolved. They are not :'( I've tried to look further, I think that the root of this problem is in core.c, in the rtl_op_bss_info_changed function. This function make a call to get_sta on the new bssid. The problem is that at this point, the sta is still not inserted, thus cannot be accessed by this method. As far as I understand the code, this specific rtl_op_bss_info_changed is responsible for setting rtlmac->mode, which explains why this mode is never set on my system.
I think the difference in our two systems is in the use of NetworkManager and the associated applet. With it, rtl_op_bss_info_changed() does not seem to be called before sta is ready.
Attached is a patch that will force mac->mode when sta has not been established. Perhaps that will be enough.
It not, I will need to set up your distro and run the wireless exactly the way you do to duplicate your results. Please provide the distro name and version, the architecture, the sequence of commands, and the contents of any special scripts you run.
Larry
Index: wireless-testing-save/drivers/net/wireless/rtlwifi/core.c =================================================================== --- wireless-testing-save.orig/drivers/net/wireless/rtlwifi/core.c +++ wireless-testing-save/drivers/net/wireless/rtlwifi/core.c @@ -832,6 +832,7 @@ static void rtl_op_bss_info_changed(stru rcu_read_lock(); sta = get_sta(hw, vif, bss_conf->bssid); if (!sta) { + mac->mode = WIRELESS_MODE_G; rcu_read_unlock(); goto out; }