nft-qos: replace input chain with prerouting for monitor and dynamic QoS as well

Signed-off-by: Rosy Song <rosysong@rosinson.com>
This commit is contained in:
Rosy Song 2018-11-12 09:42:55 +08:00
parent 79928f9278
commit cf239752d2
3 changed files with 5 additions and 5 deletions

View file

@ -8,7 +8,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=nft-qos
PKG_VERSION:=1.0.1
PKG_VERSION:=1.0.2
PKG_RELEASE:=1
PKG_LICENSE:=GPL-2.0

View file

@ -56,7 +56,7 @@ qosdef_flush_dynamic() {
# init dynamic qos
qosdef_init_dynamic() {
local dynamic_bw_up dynamic_bw_down limit_enable limit_type
local hook_ul="input" hook_dl="postrouting"
local hook_ul="prerouting" hook_dl="postrouting"
uci_validate_section nft-qos default default \
'limit_enable:bool:0' \
@ -79,7 +79,7 @@ qosdef_init_dynamic() {
[ -z "$NFT_QOS_HAS_BRIDGE" ] && {
hook_ul="postrouting"
hook_dl="input"
hook_dl="prerouting"
}
qosdef_appendx "table $NFT_QOS_INET_FAMILY nft-qos-dynamic {\n"

View file

@ -26,11 +26,11 @@ qosdef_monitor_del() { # <mac> <ip> <hostname>
# init qos monitor
qosdef_init_monitor() {
local hook_ul="input" hook_dl="postrouting"
local hook_ul="prerouting" hook_dl="postrouting"
[ -z "$NFT_QOS_HAS_BRIDGE" ] && {
hook_ul="postrouting"
hook_dl="input"
hook_dl="prerouting"
}
nft add table $NFT_QOS_INET_FAMILY nft-qos-monitor