Search Linux Wireless

mac80211: bad use of bss_conf.use_short_preamble

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,
does anyone know what values were intended to be used for
bss_conf.use_short_preamble? The way it is handled now is not
optimal for sure:

/* WLAN_ERP_BARKER_PREAMBLE values */
enum {
        WLAN_ERP_PREAMBLE_SHORT = 0,
        WLAN_ERP_PREAMBLE_LONG = 1,
};

ieee80211_reset_erp_info():
	sdata->bss_conf.use_short_preamble = 0;

ieee80211_frame_duration():
		dur += short_preamble ? (72 + 24) : (144 + 48);

ieee80211_handle_erp_ie():
	printk(KERN_DEBUG "%s: switched to %s barker preamble"
		" (BSSID=%s)\n",
		sdata->dev->name,
		(preamble_mode == WLAN_ERP_PREAMBLE_SHORT) ?
		"short" : "long",
		print_mac(mac, ifsta->bssid));


In short, the value driver receives in bss_info_changed() callback
uses WLAN_ERP_PREAMBLE_xxx constants, but ie. frame_duration() uses
0=long, 1=short semantics (reset_erp_info() probably wants to set
long preambles as well). There are more places like this I suppose.

My reason for looking at this is that if you associate to 11b AP,
the value of use_short_preamble is not set correctly - seems that
it is set only based on ERP IE and not based on capability info.
However I'm not sure yet if this is related to above inconsistency
or not, I have to dig into it.

Regards,
  Vlado



Attachment: signature.asc
Description: OpenPGP digital signature


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux