blob: 0c2070ca073c5b228e9e4c1324cf248282d2a54e [file] [log] [blame]
diff --git a/package/kernel/mac80211/Makefile b/package/kernel/mac80211/Makefile
index b7059fe6..62c13eb2 100644
--- a/package/kernel/mac80211/Makefile
+++ b/package/kernel/mac80211/Makefile
@@ -20,6 +20,7 @@ PKG_SOURCE:=backports-$(PKG_VERSION).tar.xz
PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/backports-$(PKG_VERSION)
PKG_BUILD_PARALLEL:=1
+SOURCE_PATH:=./src
PKG_MAINTAINER:=Felix Fietkau <nbd@nbd.name>
PKG_DRIVERS = \
@@ -72,6 +73,10 @@ config-y:= \
WLAN_VENDOR_ST \
WLAN_VENDOR_TI \
WLAN_VENDOR_ZYDAS \
+ MAC80211_DEBUG_MENU \
+ MAC80211_MLME_DEBUG \
+ MAC80211_STA_DEBUG \
+ MAC80211_HT_DEBUG \
config-$(call config_package,cfg80211) += CFG80211
config-$(CONFIG_PACKAGE_CFG80211_TESTMODE) += NL80211_TESTMODE
@@ -297,6 +302,8 @@ define Build/Prepare
mkdir -p $(PKG_BUILD_DIR)
$(PKG_UNPACK)
$(Build/Patch)
+ $(CP) $(SOURCE_PATH)/net $(PKG_BUILD_DIR) 2>/dev/null || :
+ $(CP) $(SOURCE_PATH)/include $(PKG_BUILD_DIR) 2>/dev/null || :
rm -rf \
$(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..ac23b3ae 100644
--- a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
+++ b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
@@ -144,9 +144,6 @@ mac80211_hostapd_setup_base() {
json_get_values ht_capab_list ht_capab
json_get_values channel_list channels
- [ "$auto_channel" = 0 ] && [ -z "$channel_list" ] && \
- channel_list="$channel"
-
[ "$min_tx_power" -gt 0 ] && append base_cfg "min_tx_power=$min_tx_power"
set_default noscan 0
@@ -315,7 +312,6 @@ mac80211_hostapd_setup_base() {
vht_link_adapt:3 \
vht160:2
- set_default tx_burst 2.0
append base_cfg "ieee80211ac=1" "$N"
vht_cap=0
for cap in $(iw phy "$phy" info | awk -F "[()]" '/VHT Capabilities/ { print $2 }'); do
@@ -484,6 +480,8 @@ mac80211_hostapd_setup_base() {
append base_cfg "he_mu_edca_ac_vo_timer=255" "$N"
fi
+ set_default tx_burst 5.9
+
hostapd_prepare_device_config "$hostapd_conf_file" nl80211
cat >> "$hostapd_conf_file" <<EOF
${channel:+channel=$channel}
@@ -517,7 +515,7 @@ mac80211_hostapd_setup_bss() {
append hostapd_cfg "wds_sta=1" "$N"
[ -n "$wds_bridge" ] && append hostapd_cfg "wds_bridge=$wds_bridge" "$N"
}
- [ "$staidx" -gt 0 -o "$start_disabled" -eq 1 ] && append hostapd_cfg "start_disabled=1" "$N"
+ [ "$start_disabled" -eq 1 ] && append hostapd_cfg "start_disabled=1" "$N"
cat >> /var/run/hostapd-$phy.conf <<EOF
$hostapd_cfg
@@ -1058,6 +1056,9 @@ mac80211_setup_vif() {
json_select ..
[ -n "$failed" ] || wireless_add_vif "$name" "$ifname"
+
+ echo "Setup SMP Affinity"
+ /sbin/smp-mt76.sh
}
get_freq() {
diff --git a/package/kernel/mac80211/files/lib/wifi/mac80211.sh b/package/kernel/mac80211/files/lib/wifi/mac80211.sh
index e24a2a63..10a3f8b4 100644
--- a/package/kernel/mac80211/files/lib/wifi/mac80211.sh
+++ b/package/kernel/mac80211/files/lib/wifi/mac80211.sh
@@ -120,6 +120,13 @@ get_band_defaults() {
mode_band="$band"
channel="$chan"
htmode="$mode"
+ if [ "$band" = "6g" ]
+ then
+ encryption=sae
+ key=12345678
+ else
+ encryption=none
+ fi
done
}
@@ -162,6 +169,8 @@ detect_mac80211() {
channel=""
htmode=""
ht_capab=""
+ encryption=""
+ key=""
get_band_defaults "$dev"
@@ -210,8 +219,12 @@ detect_mac80211() {
set wireless.default_${name}.network=lan
set wireless.default_${name}.mode=ap
set wireless.default_${name}.ssid=OpenWrt
- set wireless.default_${name}.encryption=none
+ set wireless.default_${name}.encryption=${encryption}
+
EOF
+ [ -n "$key" ] && {
+ uci -q set wireless.default_${name}.key=${key}
+ }
uci -q commit wireless
done
}
diff --git a/package/network/services/hostapd/files/hostapd.sh b/package/network/services/hostapd/files/hostapd.sh
index 8c233a4e..f2d4ad3d 100644
--- a/package/network/services/hostapd/files/hostapd.sh
+++ b/package/network/services/hostapd/files/hostapd.sh
@@ -1573,6 +1573,11 @@ wpa_supplicant_add_network() {
append network_data "mcast_rate=$mc_rate" "$N$T"
}
+ if [ "$auth_type" = "sae" ]; then
+ json_get_vars sae_pwe sae_pwe
+ [ -n "$sae_pwe" ] && echo "sae_pwe=$sae_pwe" >> "$_config"
+ fi
+
if [ "$key_mgmt" = "WPS" ]; then
echo "wps_cred_processing=1" >> "$_config"
else