diff options
author | 2017-01-29 10:17:40 +0200 | |
---|---|---|
committer | 2017-01-29 10:17:40 +0200 | |
commit | efbe56332fdf6a5c386152e4a2af3a2b56f723b5 (patch) | |
tree | 5ecfb51635965db8de794e8ce27d26393d964a59 /scripts/automation/trex_control_plane/stl/trex_stl_lib | |
parent | 2010a51c58f6ff45f0dd5bc60e8a3b71dab45bd4 (diff) |
Python HLTAPI bug in TOS calculation
Change-Id: I6b65c8af479a3bd6a562e3fa1c95e3f766c95d7d
Signed-off-by: Yaroslav Brustinov <ybrustin@cisco.com>
Diffstat (limited to 'scripts/automation/trex_control_plane/stl/trex_stl_lib')
-rwxr-xr-x | scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_hltapi.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_hltapi.py b/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_hltapi.py index cf594948..30a699c5 100755 --- a/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_hltapi.py +++ b/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_hltapi.py @@ -1536,7 +1536,7 @@ def get_TOS(user_kwargs, kwargs): if user_args & (TOS2 - TOS1) and user_args & (TOS1 - TOS2): raise STLError('You have mixed %s and %s TOS parameters' % (TOS1, TOS2)) if user_args & (TOS0 - TOS1 - TOS2): - return (kwargs['ip_precedence'] << 5) + (kwargs['ip_tos_field'] << 2) + kwargs['ip_mbz'] + return (kwargs['ip_precedence'] << 5) + (kwargs['ip_tos_field'] << 1) + kwargs['ip_mbz'] if user_args & (TOS1 - TOS2): return (kwargs['ip_precedence'] << 5) + (kwargs['ip_delay'] << 4) + (kwargs['ip_throughput'] << 3) + (kwargs['ip_reliability'] << 2) + (kwargs['ip_cost'] << 1) + kwargs['ip_reserved'] return (kwargs['ip_dscp'] << 2) + kwargs['ip_cu'] |