nl80211: Handle multiple interface combinations for P2P
The first combination may allow single-channel concurrency for P2P + managed, but there may be others that allow multi-channel concurrency. Parse all of them to find the maximum number of channels. Signed-off-by: Felix Fietkau <nbd@openwrt.org>
This commit is contained in:
parent
013359147d
commit
83c4cb5217
1 changed files with 5 additions and 3 deletions
|
@ -3444,10 +3444,12 @@ static int wiphy_info_iface_comb_process(struct wiphy_info_data *info,
|
||||||
}
|
}
|
||||||
|
|
||||||
if (combination_has_p2p && combination_has_mgd) {
|
if (combination_has_p2p && combination_has_mgd) {
|
||||||
info->p2p_concurrent = 1;
|
unsigned int num_channels =
|
||||||
info->num_multichan_concurrent =
|
|
||||||
nla_get_u32(tb_comb[NL80211_IFACE_COMB_NUM_CHANNELS]);
|
nla_get_u32(tb_comb[NL80211_IFACE_COMB_NUM_CHANNELS]);
|
||||||
return 1;
|
|
||||||
|
info->p2p_concurrent = 1;
|
||||||
|
if (info->num_multichan_concurrent < num_channels)
|
||||||
|
info->num_multichan_concurrent = num_channels;
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Reference in a new issue