diff options
Diffstat (limited to 'scripts/dpdk_setup_ports.py')
-rwxr-xr-x | scripts/dpdk_setup_ports.py | 6 |
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: |