Re: [PATCH] ACS: new hw_mode HOSTAPD_MODE_IEEE80211AG for dual band's channels

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

 



On Thu, Sep 19, 2019 at 05:31:52PM +0800, neojou@xxxxxxxxx wrote:
> A new hw_mode HOSTAPD_MODE_IEEE80211AG is proposed for ACS to
> compute 2.4G's and 5G's channels.
> 
> At before, in hostapd.conf, hw_mode=a is set for 5G only, and
> hw_mode=g is set for 2.4G only. Also hw_mode=any is special case
> only with drivers with which offloaded ACS is used. So we would
> like to suggest a new hw_mode for ACS to compute 2.4G and 5G band
> both when the driver doesn't support offloaded ACS.

Why would this need a new hw_mode=ag instead of extending the existing
hw_mode=any to cover the not-offloaded-ACS case?

> 1. A new hw_mode, HOSTAPD_MODE_IEEE80211AG is proposed, and conf->hw
>    will be set to this mode when "hw_mode=ag" is set in hostapd.conf.

I'd like to drop this part. The existing hw_mode=any and freqlist
parameters (if needed to exclude some frequencies) should work fine here
and I'd rather keep offloaded and not offloaded cases using the exact
same configuration so that the upper layer components would not need to
know whether the driver offloads ACS.

> diff --git a/src/ap/hw_features.c b/src/ap/hw_features.c
> @@ -832,6 +832,30 @@ int hostapd_acs_completed(struct hostapd_iface *iface, int err)
> +		if (iface->current_mode->mode == HOSTAPD_MODE_IEEE80211AG) {
> +			int i;
> +			enum hostapd_hw_mode target_mode;
> +
> +			if (iface->conf->channel<=14)
> +				target_mode = HOSTAPD_MODE_IEEE80211G;
> +			else
> +				target_mode = HOSTAPD_MODE_IEEE80211A;

This does not really work since there are channels 1..14 in the 5 GHz
band as well. Much more of the ACS functionality is now using
frequencies instead of channel numbers (which are unique only in
combination with the operating class) and whatever changes are done for
supporting multi-band operations should really be done in a way that
does not open such ambiguous checks even if the 5 GHz channels in that
range are not commonly used.

> diff --git a/src/drivers/driver_nl80211_capa.c b/src/drivers/driver_nl80211_capa.c
> @@ -1832,6 +1873,36 @@ wpa_driver_nl80211_postprocess_modes(struct hostapd_hw_modes *modes,
> +	/* add AG mode if 2.4GHz and 5GHz are all supported */
...

Why would this be needed? I don't really like this part at all..
Shouldn't the upper layer code be able to find the matching mode and
channel from the existing HOSTAPD_MODE_IEEE80211G/_IEEE80211A entries?

-- 
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