Search Linux Wireless

Re: [RFT] cfg80211: enable country IE support to all cfg80211 drivers

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

 



On Wed, 2009-07-29 at 18:01 -0700, Luis R. Rodriguez wrote:
> Since the bss is always set now once we are connected, if the
> bss has its own information element we refer to it and pass that
> instead of relying on mac80211's parsing.
> 
> Now all cfg80211 drivers get country IE support, automatically.
> 
> Signed-off-by: Luis R. Rodriguez <lrodriguez@xxxxxxxxxxx>
> ---
> 
> Johill, I think this is what you wanted in the end, I tested it and
> I get no country IE hint going through :( I could debug further but I'm
> done for now and gotta work on some other stuff, not sure when I can
> get back to this.

Well, you've made a critical mistake:

+       regulatory_hint_11d(wdev->wiphy,
+                           bss->information_elements,
+                           bss->len_information_elements);

needs to be

	const u8 *country_ie

	country_ie = ieee80211_bss_get_ie(&bss->pub, WLAN_EID_COUNTRY);
	if (country_ie)
		regulatory_hint_11d(wdev->wiphy,
				    country_ie + 2,
				    country_ie[1]);


It's rather likely that it doesn't come first, so whatever is in
information_elements first would end up not looking like a country IE or
having the right length, so the _11d function would just throw it out.


johannes

Attachment: signature.asc
Description: This is a digitally signed message part


[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