net/bnxt: fix packet type
[dpdk.git] / test / test / test_kni.c
index f6fb1a2..e4839cd 100644 (file)
 
 #include "test.h"
 
+#ifndef RTE_LIBRTE_KNI
+
+static int
+test_kni(void)
+{
+       printf("KNI not supported, skipping test\n");
+       return TEST_SKIPPED;
+}
+
+#else
+
 #include <rte_string_fns.h>
 #include <rte_mempool.h>
 #include <rte_ethdev.h>
@@ -74,6 +85,8 @@ static const struct rte_eth_conf port_conf = {
 static struct rte_kni_ops kni_ops = {
        .change_mtu = NULL,
        .config_network_if = NULL,
+       .config_mac_address = NULL,
+       .config_promiscusity = NULL,
 };
 
 static unsigned lcore_master, lcore_ingress, lcore_egress;
@@ -231,6 +244,8 @@ test_kni_register_handler_mp(void)
                struct rte_kni_ops ops = {
                        .change_mtu = kni_change_mtu,
                        .config_network_if = NULL,
+                       .config_mac_address = NULL,
+                       .config_promiscusity = NULL,
                };
 
                if (!kni) {
@@ -605,4 +620,6 @@ fail:
        return ret;
 }
 
+#endif
+
 REGISTER_TEST_COMMAND(kni_autotest, test_kni);