diff options
author | Neale Ranns <nranns@cisco.com> | 2018-06-07 23:48:20 -0700 |
---|---|---|
committer | Florin Coras <florin.coras@gmail.com> | 2018-07-09 21:10:53 +0000 |
commit | 947ea6222dad1ef04595c34273e9231395aef443 (patch) | |
tree | 8990854b2901ff8cc2241b9abfc99b0b4b54d517 /test/vpp_papi_provider.py | |
parent | dd47ecadcf63772a6037a1bb3715772d80e87f51 (diff) |
IGMP improvements
- Enable/Disable an interface for IGMP
- improve logging
- refactor common code
- no orphaned timers
- IGMP state changes in main thread only
- Large groups split over multiple state-change reports
- SSM range configuration API.
- more tests
Change-Id: If5674f1044e7e97274a711f47807c9ba689d7b9a
Signed-off-by: Neale Ranns <nranns@cisco.com>
Diffstat (limited to 'test/vpp_papi_provider.py')
-rw-r--r-- | test/vpp_papi_provider.py | 35 |
1 files changed, 24 insertions, 11 deletions
diff --git a/test/vpp_papi_provider.py b/test/vpp_papi_provider.py index 2d4b44764f3..5383b07fc4c 100644 --- a/test/vpp_papi_provider.py +++ b/test/vpp_papi_provider.py @@ -3474,7 +3474,14 @@ class VppPapiProvider(object): 'input_source': input_source, 'enable': enable}) - def igmp_listen(self, enable, sw_if_index, saddr, gaddr): + def igmp_enable_disable(self, sw_if_index, enable, host): + """ Enable/disable IGMP on a given interface """ + return self.api(self.papi.igmp_enable_disable, + {'enable': enable, + 'mode': host, + 'sw_if_index': sw_if_index}) + + def igmp_listen(self, filter, sw_if_index, saddrs, gaddr): """ Listen for new (S,G) on specified interface :param enable: add/del @@ -3483,20 +3490,26 @@ class VppPapiProvider(object): :param gaddr: group ip4 addr """ return self.api(self.papi.igmp_listen, - {'enable': enable, - 'sw_if_index': sw_if_index, - 'saddr': saddr, - 'gaddr': gaddr}) + { + 'group': + { + 'filter': filter, + 'sw_if_index': sw_if_index, + 'n_srcs': len(saddrs), + 'saddrs': saddrs, + 'gaddr': + { + 'address': gaddr + } + } + }) def igmp_dump(self, sw_if_index=None): """ Dump all (S,G) interface configurations """ if sw_if_index is None: - dump_all = 1 - sw_if_index = 0 - else: - dump_all = 0 - return self.api(self.papi.igmp_dump, {'sw_if_index': sw_if_index, - 'dump_all': dump_all}) + sw_if_index = 0xffffffff + return self.api(self.papi.igmp_dump, + {'sw_if_index': sw_if_index}) def igmp_clear_interface(self, sw_if_index): """ Remove all (S,G)s from specified interface |