Fix IP checksum offload metadata setup
[vpp.git] / test / vpp_papi_provider.py
index 4f7e9fe..2814ef9 100644 (file)
@@ -411,6 +411,14 @@ class VppPapiProvider(object):
                          'arp_term': arp_term,
                          'is_add': is_add})
 
+    def bd_ip_mac_add_del(self, bd_id, mac, ip, is_ipv6=0, is_add=1):
+        return self.api(self.papi.bd_ip_mac_add_del,
+                        {'bd_id': bd_id,
+                         'is_add': is_add,
+                         'is_ipv6': is_ipv6,
+                         'ip_address': ip,
+                         'mac_address': mac})
+
     def l2fib_add_del(self, mac, bd_id, sw_if_index, is_add=1, static_mac=0,
                       filter_mac=0, bvi_mac=0):
         """Create/delete L2 FIB entry.
@@ -1747,6 +1755,23 @@ class VppPapiProvider(object):
                 'oui': oui,
             })
 
+    def dhcp_client(self,
+                    sw_if_index,
+                    hostname,
+                    client_id='',
+                    is_add=1,
+                    want_dhcp_events=0):
+        return self.api(
+            self.papi.dhcp_client_config,
+            {
+                'sw_if_index': sw_if_index,
+                'hostname': hostname,
+                'client_id': client_id,
+                'is_add': is_add,
+                'want_dhcp_event': want_dhcp_events,
+                'pid': os.getpid(),
+            })
+
     def ip_mroute_add_del(self,
                           src_address,
                           grp_address,