Re: [PATCH 1/2] supported op class should take freq-list into account.

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

 



On Fri, Aug 24, 2018 at 12:01:28PM -0700, greearb@xxxxxxxxxxxxxxx wrote:
> If a station is configured to scan only a subset of frequencies,
> then the supported operating classes may need to be more limited
> than what the hardware supports.

> diff --git a/wpa_supplicant/op_classes.c b/wpa_supplicant/op_classes.c
> @@ -214,11 +215,41 @@ static int wpas_op_class_supported(struct wpa_supplicant *wpa_s,

> +	/* If we are configured to disable certain things, then take that
> +	 * into account here.
> +	 */
> +	if (wpa_s->conf->freq_list && wpa_s->conf->freq_list[0]) {

This does look correct to me. wpa_s->conf->freq_list is a constraint on
which channels are scanned by default, i.e., it does not prevent
association on a not-listed channel. As such, I don't think this should
change the Supported Operating Classes element contents. However, there
is ssid->freq_list that is used to filter BSSs for association based on
the channel. This design seems to work fine with that (after being
rebased on top of the disable_ht/vht patch to get the ssid pointer
here), so I replaced wpa_s->conf with ssid here and applied this.

> +			if (f > 3000)
> +				freq5 = 1;
> +			else if (f < 3000)
> +				freq2 = 1;

With some changes on those ranges as well to avoid strange issues if < 1
GHz, 3.6 GHz, or 60 GHz (etc.) is used.

-- 
Jouni Malinen                                            PGP id EFC895FA

_______________________________________________
Hostap mailing list
Hostap@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/hostap



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

  Powered by Linux