net/bnxt: implement TF Identifier search
[dpdk.git] / drivers / net / memif / rte_eth_memif.c
index 27c0f09..c1c7e9f 100644 (file)
@@ -1491,12 +1491,14 @@ memif_create(struct rte_vdev_device *vdev, enum memif_role_t role,
        pmd->cfg.num_m2s_rings = 0;
 
        pmd->cfg.pkt_buffer_size = pkt_buffer_size;
+       rte_spinlock_init(&pmd->cc_lock);
 
        data = eth_dev->data;
        data->dev_private = pmd;
        data->numa_node = numa_node;
        data->dev_link = pmd_link;
        data->mac_addrs = ether_addr;
+       data->promiscuous = 1;
 
        eth_dev->dev_ops = &ops;
        eth_dev->device = &vdev->device;
@@ -1509,7 +1511,7 @@ memif_create(struct rte_vdev_device *vdev, enum memif_role_t role,
        }
 
 
-       eth_dev->data->dev_flags &= RTE_ETH_DEV_CLOSE_REMOVE;
+       eth_dev->data->dev_flags |= RTE_ETH_DEV_CLOSE_REMOVE;
 
        rte_eth_dev_probing_finish(eth_dev);
 
@@ -1804,11 +1806,4 @@ RTE_PMD_REGISTER_PARAM_STRING(net_memif,
                              ETH_MEMIF_ZC_ARG "=yes|no"
                              ETH_MEMIF_SECRET_ARG "=<string>");
 
-int memif_logtype;
-
-RTE_INIT(memif_init_log)
-{
-       memif_logtype = rte_log_register("pmd.net.memif");
-       if (memif_logtype >= 0)
-               rte_log_set_level(memif_logtype, RTE_LOG_NOTICE);
-}
+RTE_LOG_REGISTER(memif_logtype, pmd.net.memif, NOTICE);