X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=drivers%2Fnet%2Fsfc%2Fsfc_ethdev.c;h=91b34eb478291284c4ce43db72bf2e558af67791;hb=f28ede500c2ed5f14cb5aa549ea1116c4e04c5f7;hp=e84731acaf2a4d53188e0db4ca03c175f3a6c4c0;hpb=295f647a38a2680de89f299adc1a50681240405a;p=dpdk.git diff --git a/drivers/net/sfc/sfc_ethdev.c b/drivers/net/sfc/sfc_ethdev.c index e84731acaf..91b34eb478 100644 --- a/drivers/net/sfc/sfc_ethdev.c +++ b/drivers/net/sfc/sfc_ethdev.c @@ -1,5 +1,7 @@ /*- - * Copyright (c) 2016 Solarflare Communications Inc. + * BSD LICENSE + * + * Copyright (c) 2016-2017 Solarflare Communications Inc. * All rights reserved. * * This software was jointly developed between OKTET Labs (under contract @@ -29,7 +31,9 @@ #include #include +#include #include +#include #include "efx.h" @@ -41,6 +45,59 @@ #include "sfc_rx.h" #include "sfc_tx.h" #include "sfc_flow.h" +#include "sfc_dp.h" +#include "sfc_dp_rx.h" + +static struct sfc_dp_list sfc_dp_head = + TAILQ_HEAD_INITIALIZER(sfc_dp_head); + +static int +sfc_fw_version_get(struct rte_eth_dev *dev, char *fw_version, size_t fw_size) +{ + struct sfc_adapter *sa = dev->data->dev_private; + efx_nic_fw_info_t enfi; + int ret; + int rc; + + /* + * Return value of the callback is likely supposed to be + * equal to or greater than 0, nevertheless, if an error + * occurs, it will be desirable to pass it to the caller + */ + if ((fw_version == NULL) || (fw_size == 0)) + return -EINVAL; + + rc = efx_nic_get_fw_version(sa->nic, &enfi); + if (rc != 0) + return -rc; + + ret = snprintf(fw_version, fw_size, + "%" PRIu16 ".%" PRIu16 ".%" PRIu16 ".%" PRIu16, + enfi.enfi_mc_fw_version[0], enfi.enfi_mc_fw_version[1], + enfi.enfi_mc_fw_version[2], enfi.enfi_mc_fw_version[3]); + if (ret < 0) + return ret; + + if (enfi.enfi_dpcpu_fw_ids_valid) { + size_t dpcpu_fw_ids_offset = MIN(fw_size - 1, (size_t)ret); + int ret_extra; + + ret_extra = snprintf(fw_version + dpcpu_fw_ids_offset, + fw_size - dpcpu_fw_ids_offset, + " rx%" PRIx16 " tx%" PRIx16, + enfi.enfi_rx_dpcpu_fw_id, + enfi.enfi_tx_dpcpu_fw_id); + if (ret_extra < 0) + return ret_extra; + + ret += ret_extra; + } + + if (fw_size < (size_t)(++ret)) + return ret; + else + return 0; +} static void sfc_dev_infos_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info) @@ -50,7 +107,7 @@ sfc_dev_infos_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info) sfc_log_init(sa, "entry"); - dev_info->pci_dev = RTE_DEV_TO_PCI(dev->device); + dev_info->pci_dev = RTE_ETH_DEV_TO_PCI(dev); dev_info->max_rx_pktlen = EFX_MAC_PDU_MAX; /* Autonegotiation may be disabled */ @@ -79,11 +136,15 @@ sfc_dev_infos_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info) DEV_TX_OFFLOAD_TCP_CKSUM; dev_info->default_txconf.txq_flags = ETH_TXQ_FLAGS_NOXSUMSCTP; - if (!encp->enc_hw_tx_insert_vlan_enabled) + if ((~sa->dp_tx->features & SFC_DP_TX_FEAT_VLAN_INSERT) || + !encp->enc_hw_tx_insert_vlan_enabled) dev_info->default_txconf.txq_flags |= ETH_TXQ_FLAGS_NOVLANOFFL; else dev_info->tx_offload_capa |= DEV_TX_OFFLOAD_VLAN_INSERT; + if (~sa->dp_tx->features & SFC_DP_TX_FEAT_MULTI_SEG) + dev_info->default_txconf.txq_flags |= ETH_TXQ_FLAGS_NOMULTSEGS; + #if EFSYS_OPT_RX_SCALE if (sa->rss_support != EFX_RX_SCALE_UNAVAILABLE) { dev_info->reta_size = EFX_RSS_TBL_SIZE; @@ -114,19 +175,9 @@ sfc_dev_infos_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info) static const uint32_t * sfc_dev_supported_ptypes_get(struct rte_eth_dev *dev) { - static const uint32_t ptypes[] = { - RTE_PTYPE_L2_ETHER, - RTE_PTYPE_L3_IPV4_EXT_UNKNOWN, - RTE_PTYPE_L3_IPV6_EXT_UNKNOWN, - RTE_PTYPE_L4_TCP, - RTE_PTYPE_L4_UDP, - RTE_PTYPE_UNKNOWN - }; - - if (dev->rx_pkt_burst == sfc_recv_pkts) - return ptypes; - - return NULL; + struct sfc_adapter *sa = dev->data->dev_private; + + return sa->dp_rx->supported_ptypes_get(); } static int @@ -142,8 +193,6 @@ sfc_dev_configure(struct rte_eth_dev *dev) sfc_adapter_lock(sa); switch (sa->state) { case SFC_ADAPTER_CONFIGURED: - sfc_close(sa); - SFC_ASSERT(sa->state == SFC_ADAPTER_INITIALIZED); /* FALLTHROUGH */ case SFC_ADAPTER_INITIALIZED: rc = sfc_configure(sa); @@ -366,7 +415,7 @@ sfc_rx_queue_setup(struct rte_eth_dev *dev, uint16_t rx_queue_id, if (rc != 0) goto fail_rx_qinit; - dev->data->rx_queues[rx_queue_id] = sa->rxq_info[rx_queue_id].rxq; + dev->data->rx_queues[rx_queue_id] = sa->rxq_info[rx_queue_id].rxq->dp; sfc_adapter_unlock(sa); @@ -381,13 +430,15 @@ fail_rx_qinit: static void sfc_rx_queue_release(void *queue) { - struct sfc_rxq *rxq = queue; + struct sfc_dp_rxq *dp_rxq = queue; + struct sfc_rxq *rxq; struct sfc_adapter *sa; unsigned int sw_index; - if (rxq == NULL) + if (dp_rxq == NULL) return; + rxq = sfc_rxq_by_dp_rxq(dp_rxq); sa = rxq->evq->sa; sfc_adapter_lock(sa); @@ -419,7 +470,7 @@ sfc_tx_queue_setup(struct rte_eth_dev *dev, uint16_t tx_queue_id, if (rc != 0) goto fail_tx_qinit; - dev->data->tx_queues[tx_queue_id] = sa->txq_info[tx_queue_id].txq; + dev->data->tx_queues[tx_queue_id] = sa->txq_info[tx_queue_id].txq->dp; sfc_adapter_unlock(sa); return 0; @@ -433,13 +484,15 @@ fail_tx_qinit: static void sfc_tx_queue_release(void *queue) { - struct sfc_txq *txq = queue; + struct sfc_dp_txq *dp_txq = queue; + struct sfc_txq *txq; unsigned int sw_index; struct sfc_adapter *sa; - if (txq == NULL) + if (dp_txq == NULL) return; + txq = sfc_txq_by_dp_txq(dp_txq); sw_index = sfc_txq_sw_index(txq); SFC_ASSERT(txq->evq != NULL); @@ -860,6 +913,10 @@ sfc_set_mc_addr_list(struct rte_eth_dev *dev, struct ether_addr *mc_addr_set, return -rc; } +/* + * The function is used by the secondary process as well. It must not + * use any process-local pointers from the adapter data. + */ static void sfc_rx_queue_info_get(struct rte_eth_dev *dev, uint16_t rx_queue_id, struct rte_eth_rxq_info *qinfo) @@ -886,6 +943,10 @@ sfc_rx_queue_info_get(struct rte_eth_dev *dev, uint16_t rx_queue_id, sfc_adapter_unlock(sa); } +/* + * The function is used by the secondary process as well. It must not + * use any process-local pointers from the adapter data. + */ static void sfc_tx_queue_info_get(struct rte_eth_dev *dev, uint16_t tx_queue_id, struct rte_eth_txq_info *qinfo) @@ -923,9 +984,9 @@ sfc_rx_queue_count(struct rte_eth_dev *dev, uint16_t rx_queue_id) static int sfc_rx_descriptor_done(void *queue, uint16_t offset) { - struct sfc_rxq *rxq = queue; + struct sfc_dp_rxq *dp_rxq = queue; - return sfc_rx_qdesc_done(rxq, offset); + return sfc_rx_qdesc_done(dp_rxq, offset); } static int @@ -1031,10 +1092,12 @@ sfc_dev_rss_hash_conf_get(struct rte_eth_dev *dev, { struct sfc_adapter *sa = dev->data->dev_private; - if ((sa->rss_channels == 1) || - (sa->rss_support != EFX_RX_SCALE_EXCLUSIVE)) + if (sa->rss_support != EFX_RX_SCALE_EXCLUSIVE) return -ENOTSUP; + if (sa->rss_channels == 0) + return -EINVAL; + sfc_adapter_lock(sa); /* @@ -1061,12 +1124,16 @@ sfc_dev_rss_hash_update(struct rte_eth_dev *dev, unsigned int efx_hash_types; int rc = 0; - if ((sa->rss_channels == 1) || - (sa->rss_support != EFX_RX_SCALE_EXCLUSIVE)) { + if (sa->rss_support != EFX_RX_SCALE_EXCLUSIVE) { sfc_err(sa, "RSS is not available"); return -ENOTSUP; } + if (sa->rss_channels == 0) { + sfc_err(sa, "RSS is not configured"); + return -EINVAL; + } + if ((rss_conf->rss_key != NULL) && (rss_conf->rss_key_len != sizeof(sa->rss_key))) { sfc_err(sa, "RSS key size is wrong (should be %lu)", @@ -1123,10 +1190,12 @@ sfc_dev_rss_reta_query(struct rte_eth_dev *dev, struct sfc_adapter *sa = dev->data->dev_private; int entry; - if ((sa->rss_channels == 1) || - (sa->rss_support != EFX_RX_SCALE_EXCLUSIVE)) + if (sa->rss_support != EFX_RX_SCALE_EXCLUSIVE) return -ENOTSUP; + if (sa->rss_channels == 0) + return -EINVAL; + if (reta_size != EFX_RSS_TBL_SIZE) return -EINVAL; @@ -1156,12 +1225,16 @@ sfc_dev_rss_reta_update(struct rte_eth_dev *dev, int rc; - if ((sa->rss_channels == 1) || - (sa->rss_support != EFX_RX_SCALE_EXCLUSIVE)) { + if (sa->rss_support != EFX_RX_SCALE_EXCLUSIVE) { sfc_err(sa, "RSS is not available"); return -ENOTSUP; } + if (sa->rss_channels == 0) { + sfc_err(sa, "RSS is not configured"); + return -EINVAL; + } + if (reta_size != EFX_RSS_TBL_SIZE) { sfc_err(sa, "RETA size is wrong (should be %u)", EFX_RSS_TBL_SIZE); @@ -1304,18 +1377,266 @@ static const struct eth_dev_ops sfc_eth_dev_ops = { .set_mc_addr_list = sfc_set_mc_addr_list, .rxq_info_get = sfc_rx_queue_info_get, .txq_info_get = sfc_tx_queue_info_get, + .fw_version_get = sfc_fw_version_get, }; +/** + * Duplicate a string in potentially shared memory required for + * multi-process support. + * + * strdup() allocates from process-local heap/memory. + */ +static char * +sfc_strdup(const char *str) +{ + size_t size; + char *copy; + + if (str == NULL) + return NULL; + + size = strlen(str) + 1; + copy = rte_malloc(__func__, size, 0); + if (copy != NULL) + rte_memcpy(copy, str, size); + + return copy; +} + +static int +sfc_eth_dev_set_ops(struct rte_eth_dev *dev) +{ + struct sfc_adapter *sa = dev->data->dev_private; + unsigned int avail_caps = 0; + const char *rx_name = NULL; + const char *tx_name = NULL; + int rc; + + switch (sa->family) { + case EFX_FAMILY_HUNTINGTON: + case EFX_FAMILY_MEDFORD: + avail_caps |= SFC_DP_HW_FW_CAP_EF10; + break; + default: + break; + } + + rc = sfc_kvargs_process(sa, SFC_KVARG_RX_DATAPATH, + sfc_kvarg_string_handler, &rx_name); + if (rc != 0) + goto fail_kvarg_rx_datapath; + + if (rx_name != NULL) { + sa->dp_rx = sfc_dp_find_rx_by_name(&sfc_dp_head, rx_name); + if (sa->dp_rx == NULL) { + sfc_err(sa, "Rx datapath %s not found", rx_name); + rc = ENOENT; + goto fail_dp_rx; + } + if (!sfc_dp_match_hw_fw_caps(&sa->dp_rx->dp, avail_caps)) { + sfc_err(sa, + "Insufficient Hw/FW capabilities to use Rx datapath %s", + rx_name); + rc = EINVAL; + goto fail_dp_rx_caps; + } + } else { + sa->dp_rx = sfc_dp_find_rx_by_caps(&sfc_dp_head, avail_caps); + if (sa->dp_rx == NULL) { + sfc_err(sa, "Rx datapath by caps %#x not found", + avail_caps); + rc = ENOENT; + goto fail_dp_rx; + } + } + + sa->dp_rx_name = sfc_strdup(sa->dp_rx->dp.name); + if (sa->dp_rx_name == NULL) { + rc = ENOMEM; + goto fail_dp_rx_name; + } + + sfc_info(sa, "use %s Rx datapath", sa->dp_rx_name); + + dev->rx_pkt_burst = sa->dp_rx->pkt_burst; + + rc = sfc_kvargs_process(sa, SFC_KVARG_TX_DATAPATH, + sfc_kvarg_string_handler, &tx_name); + if (rc != 0) + goto fail_kvarg_tx_datapath; + + if (tx_name != NULL) { + sa->dp_tx = sfc_dp_find_tx_by_name(&sfc_dp_head, tx_name); + if (sa->dp_tx == NULL) { + sfc_err(sa, "Tx datapath %s not found", tx_name); + rc = ENOENT; + goto fail_dp_tx; + } + if (!sfc_dp_match_hw_fw_caps(&sa->dp_tx->dp, avail_caps)) { + sfc_err(sa, + "Insufficient Hw/FW capabilities to use Tx datapath %s", + tx_name); + rc = EINVAL; + goto fail_dp_tx_caps; + } + } else { + sa->dp_tx = sfc_dp_find_tx_by_caps(&sfc_dp_head, avail_caps); + if (sa->dp_tx == NULL) { + sfc_err(sa, "Tx datapath by caps %#x not found", + avail_caps); + rc = ENOENT; + goto fail_dp_tx; + } + } + + sa->dp_tx_name = sfc_strdup(sa->dp_tx->dp.name); + if (sa->dp_tx_name == NULL) { + rc = ENOMEM; + goto fail_dp_tx_name; + } + + sfc_info(sa, "use %s Tx datapath", sa->dp_tx_name); + + dev->tx_pkt_burst = sa->dp_tx->pkt_burst; + + dev->dev_ops = &sfc_eth_dev_ops; + + return 0; + +fail_dp_tx_name: +fail_dp_tx_caps: + sa->dp_tx = NULL; + +fail_dp_tx: +fail_kvarg_tx_datapath: + rte_free(sa->dp_rx_name); + sa->dp_rx_name = NULL; + +fail_dp_rx_name: +fail_dp_rx_caps: + sa->dp_rx = NULL; + +fail_dp_rx: +fail_kvarg_rx_datapath: + return rc; +} + +static void +sfc_eth_dev_clear_ops(struct rte_eth_dev *dev) +{ + struct sfc_adapter *sa = dev->data->dev_private; + + dev->dev_ops = NULL; + dev->rx_pkt_burst = NULL; + dev->tx_pkt_burst = NULL; + + rte_free(sa->dp_tx_name); + sa->dp_tx_name = NULL; + sa->dp_tx = NULL; + + rte_free(sa->dp_rx_name); + sa->dp_rx_name = NULL; + sa->dp_rx = NULL; +} + +static const struct eth_dev_ops sfc_eth_dev_secondary_ops = { + .rxq_info_get = sfc_rx_queue_info_get, + .txq_info_get = sfc_tx_queue_info_get, +}; + +static int +sfc_eth_dev_secondary_set_ops(struct rte_eth_dev *dev) +{ + /* + * Device private data has really many process-local pointers. + * Below code should be extremely careful to use data located + * in shared memory only. + */ + struct sfc_adapter *sa = dev->data->dev_private; + const struct sfc_dp_rx *dp_rx; + const struct sfc_dp_tx *dp_tx; + int rc; + + dp_rx = sfc_dp_find_rx_by_name(&sfc_dp_head, sa->dp_rx_name); + if (dp_rx == NULL) { + sfc_err(sa, "cannot find %s Rx datapath", sa->dp_tx_name); + rc = ENOENT; + goto fail_dp_rx; + } + if (~dp_rx->features & SFC_DP_RX_FEAT_MULTI_PROCESS) { + sfc_err(sa, "%s Rx datapath does not support multi-process", + sa->dp_tx_name); + rc = EINVAL; + goto fail_dp_rx_multi_process; + } + + dp_tx = sfc_dp_find_tx_by_name(&sfc_dp_head, sa->dp_tx_name); + if (dp_tx == NULL) { + sfc_err(sa, "cannot find %s Tx datapath", sa->dp_tx_name); + rc = ENOENT; + goto fail_dp_tx; + } + if (~dp_tx->features & SFC_DP_TX_FEAT_MULTI_PROCESS) { + sfc_err(sa, "%s Tx datapath does not support multi-process", + sa->dp_tx_name); + rc = EINVAL; + goto fail_dp_tx_multi_process; + } + + dev->rx_pkt_burst = dp_rx->pkt_burst; + dev->tx_pkt_burst = dp_tx->pkt_burst; + dev->dev_ops = &sfc_eth_dev_secondary_ops; + + return 0; + +fail_dp_tx_multi_process: +fail_dp_tx: +fail_dp_rx_multi_process: +fail_dp_rx: + return rc; +} + +static void +sfc_eth_dev_secondary_clear_ops(struct rte_eth_dev *dev) +{ + dev->dev_ops = NULL; + dev->tx_pkt_burst = NULL; + dev->rx_pkt_burst = NULL; +} + +static void +sfc_register_dp(void) +{ + /* Register once */ + if (TAILQ_EMPTY(&sfc_dp_head)) { + /* Prefer EF10 datapath */ + sfc_dp_register(&sfc_dp_head, &sfc_ef10_rx.dp); + sfc_dp_register(&sfc_dp_head, &sfc_efx_rx.dp); + + sfc_dp_register(&sfc_dp_head, &sfc_ef10_tx.dp); + sfc_dp_register(&sfc_dp_head, &sfc_efx_tx.dp); + sfc_dp_register(&sfc_dp_head, &sfc_ef10_simple_tx.dp); + } +} + static int sfc_eth_dev_init(struct rte_eth_dev *dev) { struct sfc_adapter *sa = dev->data->dev_private; - struct rte_pci_device *pci_dev = SFC_DEV_TO_PCI(dev); + struct rte_pci_device *pci_dev = RTE_ETH_DEV_TO_PCI(dev); int rc; const efx_nic_cfg_t *encp; const struct ether_addr *from; + sfc_register_dp(); + + if (rte_eal_process_type() != RTE_PROC_PRIMARY) + return -sfc_eth_dev_secondary_set_ops(dev); + /* Required for logging */ + sa->pci_addr = pci_dev->addr; + sa->port_id = dev->data->port_id; + sa->eth_dev = dev; /* Copy PCI device info to the dev->data */ @@ -1341,6 +1662,16 @@ sfc_eth_dev_init(struct rte_eth_dev *dev) sfc_adapter_lock_init(sa); sfc_adapter_lock(sa); + sfc_log_init(sa, "probing"); + rc = sfc_probe(sa); + if (rc != 0) + goto fail_probe; + + sfc_log_init(sa, "set device ops"); + rc = sfc_eth_dev_set_ops(dev); + if (rc != 0) + goto fail_set_ops; + sfc_log_init(sa, "attaching"); rc = sfc_attach(sa); if (rc != 0) @@ -1355,16 +1686,18 @@ sfc_eth_dev_init(struct rte_eth_dev *dev) from = (const struct ether_addr *)(encp->enc_mac_addr); ether_addr_copy(from, &dev->data->mac_addrs[0]); - dev->dev_ops = &sfc_eth_dev_ops; - dev->rx_pkt_burst = &sfc_recv_pkts; - dev->tx_pkt_burst = &sfc_xmit_pkts; - sfc_adapter_unlock(sa); sfc_log_init(sa, "done"); return 0; fail_attach: + sfc_eth_dev_clear_ops(dev); + +fail_set_ops: + sfc_unprobe(sa); + +fail_probe: sfc_adapter_unlock(sa); sfc_adapter_lock_fini(sa); rte_free(dev->data->mac_addrs); @@ -1383,21 +1716,26 @@ fail_kvargs_parse: static int sfc_eth_dev_uninit(struct rte_eth_dev *dev) { - struct sfc_adapter *sa = dev->data->dev_private; + struct sfc_adapter *sa; + if (rte_eal_process_type() != RTE_PROC_PRIMARY) { + sfc_eth_dev_secondary_clear_ops(dev); + return 0; + } + + sa = dev->data->dev_private; sfc_log_init(sa, "entry"); sfc_adapter_lock(sa); + sfc_eth_dev_clear_ops(dev); + sfc_detach(sa); + sfc_unprobe(sa); rte_free(dev->data->mac_addrs); dev->data->mac_addrs = NULL; - dev->dev_ops = NULL; - dev->rx_pkt_burst = NULL; - dev->tx_pkt_burst = NULL; - sfc_kvargs_cleanup(sa); sfc_adapter_unlock(sa); @@ -1412,29 +1750,42 @@ sfc_eth_dev_uninit(struct rte_eth_dev *dev) static const struct rte_pci_id pci_id_sfc_efx_map[] = { { RTE_PCI_DEVICE(EFX_PCI_VENID_SFC, EFX_PCI_DEVID_FARMINGDALE) }, + { RTE_PCI_DEVICE(EFX_PCI_VENID_SFC, EFX_PCI_DEVID_FARMINGDALE_VF) }, { RTE_PCI_DEVICE(EFX_PCI_VENID_SFC, EFX_PCI_DEVID_GREENPORT) }, + { RTE_PCI_DEVICE(EFX_PCI_VENID_SFC, EFX_PCI_DEVID_GREENPORT_VF) }, { RTE_PCI_DEVICE(EFX_PCI_VENID_SFC, EFX_PCI_DEVID_MEDFORD) }, + { RTE_PCI_DEVICE(EFX_PCI_VENID_SFC, EFX_PCI_DEVID_MEDFORD_VF) }, { .vendor_id = 0 /* sentinel */ } }; -static struct eth_driver sfc_efx_pmd = { - .pci_drv = { - .id_table = pci_id_sfc_efx_map, - .drv_flags = - RTE_PCI_DRV_INTR_LSC | - RTE_PCI_DRV_NEED_MAPPING, - .probe = rte_eth_dev_pci_probe, - .remove = rte_eth_dev_pci_remove, - }, - .eth_dev_init = sfc_eth_dev_init, - .eth_dev_uninit = sfc_eth_dev_uninit, - .dev_private_size = sizeof(struct sfc_adapter), +static int sfc_eth_dev_pci_probe(struct rte_pci_driver *pci_drv __rte_unused, + struct rte_pci_device *pci_dev) +{ + return rte_eth_dev_pci_generic_probe(pci_dev, + sizeof(struct sfc_adapter), sfc_eth_dev_init); +} + +static int sfc_eth_dev_pci_remove(struct rte_pci_device *pci_dev) +{ + return rte_eth_dev_pci_generic_remove(pci_dev, sfc_eth_dev_uninit); +} + +static struct rte_pci_driver sfc_efx_pmd = { + .id_table = pci_id_sfc_efx_map, + .drv_flags = + RTE_PCI_DRV_INTR_LSC | + RTE_PCI_DRV_NEED_MAPPING, + .probe = sfc_eth_dev_pci_probe, + .remove = sfc_eth_dev_pci_remove, }; -RTE_PMD_REGISTER_PCI(net_sfc_efx, sfc_efx_pmd.pci_drv); +RTE_PMD_REGISTER_PCI(net_sfc_efx, sfc_efx_pmd); RTE_PMD_REGISTER_PCI_TABLE(net_sfc_efx, pci_id_sfc_efx_map); -RTE_PMD_REGISTER_KMOD_DEP(net_sfc_efx, "* igb_uio | uio_pci_generic | vfio"); +RTE_PMD_REGISTER_KMOD_DEP(net_sfc_efx, "* igb_uio | uio_pci_generic | vfio-pci"); RTE_PMD_REGISTER_PARAM_STRING(net_sfc_efx, + SFC_KVARG_RX_DATAPATH "=" SFC_KVARG_VALUES_RX_DATAPATH " " + SFC_KVARG_TX_DATAPATH "=" SFC_KVARG_VALUES_TX_DATAPATH " " SFC_KVARG_PERF_PROFILE "=" SFC_KVARG_VALUES_PERF_PROFILE " " + SFC_KVARG_STATS_UPDATE_PERIOD_MS "= " SFC_KVARG_MCDI_LOGGING "=" SFC_KVARG_VALUES_BOOL " " SFC_KVARG_DEBUG_INIT "=" SFC_KVARG_VALUES_BOOL);