mirror of
https://github.com/Telecominfraproject/wlan-ap.git
synced 2025-10-29 17:42:41 +00:00
35 lines
811 B
Diff
35 lines
811 B
Diff
--- a/src/ap/hostapd.c
|
|
+++ b/src/ap/hostapd.c
|
|
@@ -11,6 +11,8 @@
|
|
#include <sqlite3.h>
|
|
#endif /* CONFIG_SQLITE */
|
|
|
|
+#include <syslog.h>
|
|
+
|
|
#include "utils/common.h"
|
|
#include "utils/eloop.h"
|
|
#include "utils/crc32.h"
|
|
@@ -1198,6 +1200,22 @@ int hostapd_setup_bss(struct hostapd_dat
|
|
os_memcpy(hapd->own_addr, if_addr, ETH_ALEN);
|
|
}
|
|
|
|
+ if (conf->wds_sta) {
|
|
+ char path[128];
|
|
+ FILE *fp;
|
|
+
|
|
+ sprintf(path, "/sys/kernel/debug/ieee80211/%s/netdev:%s/disable_offload", hostapd_drv_get_radio_name(hapd), conf->iface);
|
|
+
|
|
+ fp = fopen(path, "w");
|
|
+ if (fp) {
|
|
+ syslog(0, "WDS: disable encap - %s\n", path);
|
|
+ fprintf(fp, "1");
|
|
+ fclose(fp);
|
|
+ } else {
|
|
+ syslog(0, "WDS: failed to disable encap - %s\n", path);
|
|
+ }
|
|
+ }
|
|
+
|
|
if (conf->wmm_enabled < 0)
|
|
conf->wmm_enabled = hapd->iconf->ieee80211n;
|
|
|