summaryrefslogtreecommitdiff
path: root/package/network/services/hostapd/patches/510-wpa_supplicant_p2p_parse_ifcomb.patch
blob: c2923cfca72d32b7d35fcbd1bee9cfd7fc68014f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
--- a/src/drivers/driver_nl80211.c
+++ b/src/drivers/driver_nl80211.c
@@ -3444,10 +3444,12 @@ static int wiphy_info_iface_comb_process
 	}
 
 	if (combination_has_p2p && combination_has_mgd) {
-		info->p2p_concurrent = 1;
-		info->num_multichan_concurrent =
+		int 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;