[openwrt/openwrt] hostapd: fix incorrect service name
LEDE Commits
lede-commits at lists.infradead.org
Fri Jul 31 13:53:14 EDT 2020
blocktrron pushed a commit to openwrt/openwrt.git, branch master:
https://git.openwrt.org/8b3e170526cf0f1d9b15a6dd7787789d15e52cd4
commit 8b3e170526cf0f1d9b15a6dd7787789d15e52cd4
Author: David Bauer <mail at david-bauer.net>
AuthorDate: Fri Jul 31 19:51:51 2020 +0200
hostapd: fix incorrect service name
When retrieving the PID for hostapd and wpa_supplicant via ubus the
wrong service name is currently used. This leads to the following error
in the log:
netifd: radio0 (1409): WARNING (wireless_add_process):
executable path /usr/sbin/wpad does not match process path (/proc/exe)
Fixing the service name retrieves the correct PID and therefore the
warning won't occur.
Signed-off-by: David Bauer <mail at david-bauer.net>
---
package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh | 2 +-
package/network/services/hostapd/files/hostapd.sh | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
index 5214704830..864b15e120 100644
--- a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
+++ b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
@@ -993,7 +993,7 @@ drv_mac80211_setup() {
add_ap=1
ubus wait_for hostapd
ubus call hostapd config_add "{\"iface\":\"$primary_ap\", \"config\":\"${hostapd_conf_file}\"}"
- local hostapd_pid=$(ubus call service list '{"name": "hostapd"}' | jsonfilter -l 1 -e "@['hostapd'].instances['hostapd'].pid")
+ local hostapd_pid=$(ubus call service list '{"name": "wpad"}' | jsonfilter -l 1 -e "@['wpad'].instances['hostapd'].pid")
wireless_add_process "$hostapd_pid" "/usr/sbin/hostapd" 1
fi
ret="$?"
diff --git a/package/network/services/hostapd/files/hostapd.sh b/package/network/services/hostapd/files/hostapd.sh
index f4e2aa559c..268a41a82b 100644
--- a/package/network/services/hostapd/files/hostapd.sh
+++ b/package/network/services/hostapd/files/hostapd.sh
@@ -1125,7 +1125,7 @@ wpa_supplicant_run() {
[ "$ret" != 0 ] && wireless_setup_vif_failed WPA_SUPPLICANT_FAILED
- local supplicant_pid=$(ubus call service list '{"name": "hostapd"}' | jsonfilter -l 1 -e "@['hostapd'].instances['supplicant'].pid")
+ local supplicant_pid=$(ubus call service list '{"name": "wpad"}' | jsonfilter -l 1 -e "@['wpad'].instances['supplicant'].pid")
wireless_add_process "$supplicant_pid" "/usr/sbin/wpa_supplicant" 1
return $ret
More information about the lede-commits
mailing list