X-Git-Url: https://gerrit.fd.io/r/gitweb?p=csit.git;a=blobdiff_plain;f=resources%2Flibraries%2Fpython%2FTRexConfigGenerator.py;h=5ecde86dcbe9c7dfc3004d0706e0781dd5a1b838;hp=2015b09ad22a46989b53c11aa0a4b71c1a4dbfe5;hb=889af5ca17aa11ccaa65fce188f72890e495cfa2;hpb=06d9ceaaffd3183155610a60e4897ebbab64384e diff --git a/resources/libraries/python/TRexConfigGenerator.py b/resources/libraries/python/TRexConfigGenerator.py index 2015b09ad2..5ecde86dcb 100644 --- a/resources/libraries/python/TRexConfigGenerator.py +++ b/resources/libraries/python/TRexConfigGenerator.py @@ -244,7 +244,7 @@ class TrexInitConfig: latency_thread_id = None cores = None limit_memory = f"{Constants.TREX_LIMIT_MEMORY}" - sockets = 0 + sockets = list() for link in tg_topology: pci_addresses.append( @@ -264,8 +264,8 @@ class TrexInitConfig: dst_mac=link["dst_mac"] ) ) - sockets = sockets | socket - if sockets: + sockets.append(socket) + if 0 in sockets and 1 in sockets: limit_memory = ( f"{Constants.TREX_LIMIT_MEMORY},{Constants.TREX_LIMIT_MEMORY}" )