X-Git-Url: https://gerrit.fd.io/r/gitweb?p=csit.git;a=blobdiff_plain;f=resources%2Flibraries%2Fpython%2FInterfaceUtil.py;h=2980afa34972408d81598af8a926074f60aca4e0;hp=6c763134f445c528c5df1332993a31fbe6fd8850;hb=eb4515115a69f5a3fe9b2fe178110cc5ff78b73a;hpb=2fa7bbfebc28b365ca4a5db6513c0be82aaecee8 diff --git a/resources/libraries/python/InterfaceUtil.py b/resources/libraries/python/InterfaceUtil.py index 6c763134f4..2980afa349 100644 --- a/resources/libraries/python/InterfaceUtil.py +++ b/resources/libraries/python/InterfaceUtil.py @@ -225,6 +225,9 @@ class InterfaceUtil(object): """ if_data = InterfaceUtil.vpp_get_interface_data(node, interface) + if if_data['sup_sw_if_index'] != if_data['sw_if_index']: + if_data = InterfaceUtil.vpp_get_interface_data( + node, if_data['sup_sw_if_index']) mac_data = [str(hex(item))[2:] for item in if_data['l2_address'][:6]] mac_data_nice = [] for item in mac_data: @@ -262,8 +265,6 @@ class InterfaceUtil(object): for item in data: item["netmask"] = convert_ipv4_netmask_prefix( item["prefix_length"]) - # VAT returns addresses with reversed byte order (VPP-132) - item["ip"] = ".".join(item["ip"].split(".")[::-1]) return data @staticmethod