summaryrefslogtreecommitdiffstats
path: root/scripts/dpdk_setup_ports.py
diff options
context:
space:
mode:
authorHanoh Haim <hhaim@cisco.com>2016-12-11 17:05:18 +0200
committerHanoh Haim <hhaim@cisco.com>2016-12-11 17:05:18 +0200
commitc8410413e0c7aea0aa353b7d5dd85b0d96766197 (patch)
tree0569b2a7f8c2bbba7094ca3ec933ecf583874eb2 /scripts/dpdk_setup_ports.py
parent229352c5fd4c9241ee333a50b96761fadfd7d940 (diff)
Cantos MTU is printed in a different way
Signed-off-by: Hanoh Haim <hhaim@cisco.com>
Diffstat (limited to 'scripts/dpdk_setup_ports.py')
-rwxr-xr-xscripts/dpdk_setup_ports.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/dpdk_setup_ports.py b/scripts/dpdk_setup_ports.py
index e445a402..ce6d2b2f 100755
--- a/scripts/dpdk_setup_ports.py
+++ b/scripts/dpdk_setup_ports.py
@@ -324,7 +324,11 @@ Other network devices
if obj:
return int(obj.group(1));
else:
- return -1
+ obj=re.search(r'mtu (\d+)',out,flags=re.MULTILINE|re.DOTALL);
+ if obj:
+ return int(obj.group(1));
+ else:
+ return -1
def set_mtu_mlx5 (self,dev_id,new_mtu):
if len(dev_id)>0: