From a304d305cb364e5c00d6d5b1ad0bc61041602256 Mon Sep 17 00:00:00 2001 From: Stephen Hemminger Date: Sat, 12 Apr 2008 14:45:19 -0700 Subject: Limit Qos priority values HTB in kernel only accepts 0-7 anything higher is rounded down to 7. (see TC_HTB_NUMPRIO). Apply syntax checks to limit to that range and add better help. Fixes: 3098 --- .../traffic-shaper/node.tag/class/node.tag/priority/node.def | 7 +++++-- .../qos-policy/traffic-shaper/node.tag/default/priority/node.def | 6 ++++-- 2 files changed, 9 insertions(+), 4 deletions(-) (limited to 'templates') diff --git a/templates/qos-policy/traffic-shaper/node.tag/class/node.tag/priority/node.def b/templates/qos-policy/traffic-shaper/node.tag/class/node.tag/priority/node.def index 4aa2d69..024eac4 100644 --- a/templates/qos-policy/traffic-shaper/node.tag/class/node.tag/priority/node.def +++ b/templates/qos-policy/traffic-shaper/node.tag/class/node.tag/priority/node.def @@ -1,3 +1,6 @@ type: u32 -help: Priority for usage of excess bandwidth -syntax:expression: ($VAR(@) > 0 && $VAR(@) < 1000) ; "priority must be between 1 and 1000" +syntax:expression: $VAR(@) >= 0 && $VAR(@) < 8 ; "priority must be between 0 than 7" +help: Priority value +comp_help: Priority for usage of excess bandwidth + <0-7> (default 0) + diff --git a/templates/qos-policy/traffic-shaper/node.tag/default/priority/node.def b/templates/qos-policy/traffic-shaper/node.tag/default/priority/node.def index d4f3391..f56d269 100644 --- a/templates/qos-policy/traffic-shaper/node.tag/default/priority/node.def +++ b/templates/qos-policy/traffic-shaper/node.tag/default/priority/node.def @@ -1,3 +1,5 @@ type: u32 -help: Priority for usage of extra bandwidth -syntax:expression: ($VAR(@) > 0 && $VAR(@) < 1000) ; "priority must be between 1 and 1000" +syntax:expression: $VAR(@) >= 0 && $VAR(@) < 8 ; "priority must be between 0 than 7" +help: Priority value +comp_help: Priority for usage of excess bandwidth + <0-7> (default 0) -- cgit v1.2.3