diff options
author | ahothan <ahothan@cisco.com> | 2019-02-24 11:53:00 -0800 |
---|---|---|
committer | ahothan <ahothan@cisco.com> | 2019-02-24 11:53:00 -0800 |
commit | afb3ff0092801294a8a7893c24440cfd321f6e56 (patch) | |
tree | a78c333ca6ece8958caa0fa54796a2974ccac955 | |
parent | e3d806ce064bade2ad168c9df03e3cc2ee396cff (diff) |
NFVBENCH-122 Allow config to have more dest MACs than chains requested
Change-Id: I887cf14e76ae59abfec6fea5bd2181d8b3238d4c
Signed-off-by: ahothan <ahothan@cisco.com>
-rwxr-xr-x | nfvbench/traffic_client.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/nfvbench/traffic_client.py b/nfvbench/traffic_client.py index 13ebfb7..58ae345 100755 --- a/nfvbench/traffic_client.py +++ b/nfvbench/traffic_client.py @@ -391,10 +391,11 @@ class GeneratorConfig(object): port_index: the port for which dest macs must be set dest_macs: a list of dest MACs indexed by chain id """ - if len(dest_macs) != self.config.service_chain_count: + if len(dest_macs) < self.config.service_chain_count: raise TrafficClientException('Dest MAC list %s must have %d entries' % (dest_macs, self.config.service_chain_count)) - self.devices[port_index].set_dest_macs(dest_macs) + # only pass the first scc dest MACs + self.devices[port_index].set_dest_macs(dest_macs[:self.config.service_chain_count]) LOG.info('Port %d: dst MAC %s', port_index, [str(mac) for mac in dest_macs]) def set_vtep_dest_macs(self, port_index, dest_macs): |