]> git.ipfire.org Git - people/stevee/network.git/commitdiff
hostapd: Always enable all HT caps
authorMichael Tremer <michael.tremer@ipfire.org>
Wed, 19 Sep 2018 13:02:09 +0000 (14:02 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Wed, 19 Sep 2018 13:02:09 +0000 (14:02 +0100)
Signed-off-by: Arne Fitzenreiter <arne.fitzenreiter@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/functions/functions.hostapd
src/functions/functions.wireless

index 8645828979a61b2d870ae0dba5912a3709fc7b90..433d172272d0799bfc7641283d9e23072b29f78c 100644 (file)
@@ -99,6 +99,9 @@ hostapd_config_write() {
                assert isset key
        fi
 
+       # Get HT caps
+       local ht_caps="$(wireless_get_ht_caps "${device}")"
+
        # Create configuration directory.
        local config_dir=$(dirname ${file})
        mkdir -p ${HOSTAPD_CONTROL_INTERFACE_DIR} ${config_dir} 2>/dev/null
@@ -151,6 +154,9 @@ hostapd_config_write() {
                # WMM
                print "wmm_enabled=${wmm}"
 
+               # Enable HT caps
+               print "ht_capab=${ht_caps}"
+
                print
        ) >> ${file}
 
index 7697c5d8735361a8ccb81952bb53e1045ef8bdf6..bf09a50935351766daf3c7310cf9b65b637f8308 100644 (file)
@@ -445,3 +445,16 @@ wireless_monitor() {
 
        return ${EXIT_OK}
 }
+
+wireless_get_ht_caps() {
+       local device="${1}"
+       assert isset device
+
+       local phy="$(device_get_phy "${device}")"
+       if ! isset phy; then
+               log ERROR "Could not determine PHY for ${device}"
+               return ${EXIT_ERROR}
+       fi
+
+       network-phy-list-ht-caps "${phy}"
+}