From 4ecb9289efea7c49b9128f4bf43a55875886ba54 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Fri, 18 Jul 2014 11:25:07 +0000 Subject: [PATCH] qos-scripts: convert to procd Signed-off-by: John Crispin Signed-off-by: Felix Fietkau SVN-Revision: 41730 --- .../config/qos-scripts/files/etc/init.d/qos | 22 ++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/package/network/config/qos-scripts/files/etc/init.d/qos b/package/network/config/qos-scripts/files/etc/init.d/qos index 3f711155ee..712d906f03 100755 --- a/package/network/config/qos-scripts/files/etc/init.d/qos +++ b/package/network/config/qos-scripts/files/etc/init.d/qos @@ -2,15 +2,27 @@ # Copyright (C) 2006 OpenWrt.org START=50 +USE_PROCD=1 -boot() { - /usr/lib/qos/generate.sh firewall | sh +validate_qos_section() +{ + uci_validate_section qos interface "${1}" \ + 'enabled:bool' \ + 'upload:uinteger' \ + 'download:uinteger' } -start() { +service_triggers() +{ + procd_add_reload_trigger "qos" + procd_add_validation validate_qos_section qos-start } -stop() { - qos-stop +start_service() { + qos-start +} + +reload_service() { + qos-start } -- 2.30.2