aboutsummaryrefslogtreecommitdiffstats
path: root/package/network/config/qos-scripts
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2014-07-18 11:25:07 +0000
committerFelix Fietkau <nbd@openwrt.org>2014-07-18 11:25:07 +0000
commit4ecb9289efea7c49b9128f4bf43a55875886ba54 (patch)
treeb0f05a4eb3eece7c018af794f401cd1909148dc7 /package/network/config/qos-scripts
parent48494962d123def9e5c3eaf47227037ef58fbd6f (diff)
downloadupstream-4ecb9289efea7c49b9128f4bf43a55875886ba54.tar.gz
upstream-4ecb9289efea7c49b9128f4bf43a55875886ba54.tar.bz2
upstream-4ecb9289efea7c49b9128f4bf43a55875886ba54.zip
qos-scripts: convert to procd
Signed-off-by: John Crispin <blogic@openwrt.org> Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 41730
Diffstat (limited to 'package/network/config/qos-scripts')
-rwxr-xr-xpackage/network/config/qos-scripts/files/etc/init.d/qos22
1 files 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
}