Currently, when no forced channel frequency is included with the start
an autonomous P2P GO command, a 6 GHz channel might get selected if it
is a shared radio frequency irrespective of P2P 6 GHz capability. In
these cases we need to check whether P2P 6 GHz capability is supported
before proceeding with P2P GO start on a 6 GHz channel.
Signed-off-by: Shivani Baranwal <quic_shivbara@quicinc.com>
const struct p2p_channels *channels,
int freq)
{
+ if (is_6ghz_freq(freq) &&
+ !is_p2p_6ghz_capable(wpa_s->global->p2p))
+ return 0;
+
if (!wpas_p2p_disallowed_freq(wpa_s->global, freq) &&
p2p_supported_freq_go(wpa_s->global->p2p, freq) &&
freq_included(wpa_s, channels, freq))