[][MAC80211][misc][Remove duplicate group cipher setting in wpa_supplicant]

[Description]
Remove duplicate group cipher setting in wpa_supplicant.

[Release-log]
N/A

Change-Id: I0ce77efee1ea935b78a4bcd068252852915478ed
Reviewed-on: https://gerrit.mediatek.inc/c/openwrt/feeds/mtk_openwrt_feeds/+/7793463
diff --git a/autobuild_mac80211_release/0001-master-mac80211-generate-hostapd-setting-from-ap-cap.patch b/autobuild_mac80211_release/0001-master-mac80211-generate-hostapd-setting-from-ap-cap.patch
index 264d818..ee11653 100644
--- a/autobuild_mac80211_release/0001-master-mac80211-generate-hostapd-setting-from-ap-cap.patch
+++ b/autobuild_mac80211_release/0001-master-mac80211-generate-hostapd-setting-from-ap-cap.patch
@@ -1,5 +1,5 @@
 diff --git a/package/kernel/mac80211/Makefile b/package/kernel/mac80211/Makefile
-index a7472ee7..f06c889b 100644
+index a7472ee779..f06c889b0a 100644
 --- a/package/kernel/mac80211/Makefile
 +++ b/package/kernel/mac80211/Makefile
 @@ -20,6 +20,7 @@ PKG_SOURCE:=backports-$(PKG_VERSION).tar.xz
@@ -31,7 +31,7 @@
  		$(PKG_BUILD_DIR)/include/linux/ssb \
  		$(PKG_BUILD_DIR)/include/linux/bcma \
 diff --git a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
-index 5aaba9af..e6e9e540 100644
+index 5aaba9af26..e6e9e540e4 100644
 --- a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
 +++ b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
 @@ -27,6 +27,7 @@ drv_mac80211_init_device_config() {
@@ -462,7 +462,7 @@
  	NEWUMLIST=
  
 diff --git a/package/kernel/mac80211/files/lib/wifi/mac80211.sh b/package/kernel/mac80211/files/lib/wifi/mac80211.sh
-index e24a2a63..20e60688 100644
+index e24a2a634e..20e60688ea 100644
 --- a/package/kernel/mac80211/files/lib/wifi/mac80211.sh
 +++ b/package/kernel/mac80211/files/lib/wifi/mac80211.sh
 @@ -60,6 +60,9 @@ BEGIN {
@@ -607,7 +607,7 @@
  	done
  }
 diff --git a/package/network/services/hostapd/files/hostapd.sh b/package/network/services/hostapd/files/hostapd.sh
-index bf3625c9..6ce28b4c 100644
+index bf3625c92d..d98ff0e9c0 100644
 --- a/package/network/services/hostapd/files/hostapd.sh
 +++ b/package/network/services/hostapd/files/hostapd.sh
 @@ -60,7 +60,14 @@ hostapd_append_wpa_key_mgmt() {
@@ -843,10 +843,14 @@
  EOF
  	return 0
  }
-@@ -1531,12 +1635,43 @@ wpa_supplicant_add_network() {
+@@ -1531,12 +1635,38 @@ wpa_supplicant_add_network() {
  		;;
  	esac
  
+-	[ "$wpa_cipher" = GCMP ] && {
+-		append network_data "pairwise=GCMP" "$N$T"
+-		append network_data "group=GCMP" "$N$T"
+-	}
 +	json_get_values pairwise pairwise
 +	if [ -n "$pairwise" ]; then
 +		case "$pairwise" in
@@ -874,11 +878,6 @@
 +		esac
 +	fi
 +	[ -n "$wpa_cipher" ] && wpa_pairwise="$wpa_cipher"
-+
- 	[ "$wpa_cipher" = GCMP ] && {
- 		append network_data "pairwise=GCMP" "$N$T"
- 		append network_data "group=GCMP" "$N$T"
- 	}
  
  	[ "$mode" = mesh ] || {
 +		json_get_values sae_groups sae_groups
@@ -887,7 +886,7 @@
  		case "$wpa" in
  			1)
  				append network_data "proto=WPA" "$N$T"
-@@ -1546,12 +1681,48 @@ wpa_supplicant_add_network() {
+@@ -1546,12 +1676,48 @@ wpa_supplicant_add_network() {
  			;;
  		esac
  
@@ -937,7 +936,7 @@
  	[ -n "$bssid" ] && append network_data "bssid=$bssid" "$N$T"
  	[ -n "$beacon_int" ] && append network_data "beacon_int=$beacon_int" "$N$T"
  
-@@ -1562,6 +1733,20 @@ wpa_supplicant_add_network() {
+@@ -1562,6 +1728,20 @@ wpa_supplicant_add_network() {
  	[ -n "$bssid_blacklist" ] && append network_data "bssid_blacklist=$bssid_blacklist" "$N$T"
  	[ -n "$bssid_whitelist" ] && append network_data "bssid_whitelist=$bssid_whitelist" "$N$T"
  
@@ -958,7 +957,7 @@
  	[ -n "$basic_rate" ] && {
  		local br rate_list=
  		for br in $basic_rate; do
-@@ -1576,6 +1761,11 @@ wpa_supplicant_add_network() {
+@@ -1576,6 +1756,11 @@ wpa_supplicant_add_network() {
  		append network_data "mcast_rate=$mc_rate" "$N$T"
  	}