Fix 5 GHz to 2.4 GHz channel switch with hostapd through DISABLE/ENABLE
When moving a 5 GHz VHT AP to 2.4 GHz band with VHT disabled through the
hostapd control interface DISABLE/reconfig/ENABLE commands, enabling of
the AP on 2.4 GHz failed due to the previously configured VHT capability
being compared with hardware VHT capability on 2.4 GHz band:
hw vht capab: 0x0, conf vht capab: 0x33800132
Configured VHT capability [VHT_CAP_MAX_MPDU_LENGTH_MASK] exceeds max value supported by the driver (2 > 0)
ap: interface state DISABLED->DISABLED
Since VHT (ieee80211ac) config is already disabled for the 2.4 GHz band,
add fix this by validating vht_capab only when VHT is enabled.
Fixes: c781eb8428
("hostapd: Verify VHT capabilities are supported by driver")
Signed-off-by: Sathishkumar Muruganandam <murugana@codeaurora.org>
This commit is contained in:
parent
349c49bac4
commit
72a09d43fe
1 changed files with 2 additions and 1 deletions
|
@ -679,7 +679,8 @@ int hostapd_check_ht_capab(struct hostapd_iface *iface)
|
||||||
if (!ieee80211n_supported_ht_capab(iface))
|
if (!ieee80211n_supported_ht_capab(iface))
|
||||||
return -1;
|
return -1;
|
||||||
#ifdef CONFIG_IEEE80211AC
|
#ifdef CONFIG_IEEE80211AC
|
||||||
if (!ieee80211ac_supported_vht_capab(iface))
|
if (iface->conf->ieee80211ac &&
|
||||||
|
!ieee80211ac_supported_vht_capab(iface))
|
||||||
return -1;
|
return -1;
|
||||||
#endif /* CONFIG_IEEE80211AC */
|
#endif /* CONFIG_IEEE80211AC */
|
||||||
ret = ieee80211n_check_40mhz(iface);
|
ret = ieee80211n_check_40mhz(iface);
|
||||||
|
|
Loading…
Reference in a new issue