From 9f10875134c239278a93acf70b164e4e9915182e Mon Sep 17 00:00:00 2001
From: Meng <x.meng@genexis.eu>
Date: Thu, 19 Dec 2019 12:27:17 +0100
Subject: [PATCH] Wifi performance issues on non-default networks

ppacmd only accept "lan" or "wan" as the network name,
thus, any other network will not be added into acceleration.
---
 lq-wave-300_5_x/files/etc/hotplug.d/net/00-wifi-detect | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/lq-wave-300_5_x/files/etc/hotplug.d/net/00-wifi-detect b/lq-wave-300_5_x/files/etc/hotplug.d/net/00-wifi-detect
index 0029b96..e9397af 100644
--- a/lq-wave-300_5_x/files/etc/hotplug.d/net/00-wifi-detect
+++ b/lq-wave-300_5_x/files/etc/hotplug.d/net/00-wifi-detect
@@ -27,7 +27,12 @@ wlan_ppa_process() {
 
 	config_get network $cfg network
 
-	wlan_ppa_${ACTION} $network $ifname
+	lan=$(uci get network.$network.is_lan 2>/dev/null)
+	if [ "$lan" == "1" ]; then
+		wlan_ppa_${ACTION} lan $ifname
+	else
+		wlan_ppa_${ACTION} wan $ifname
+	fi
 }
 
 [ "${INTERFACE%%[0-9.]*}" != "wlan" ] && return
-- 
GitLab