summaryrefslogtreecommitdiffstats
path: root/src/plugins/dpdk/device/init.c
diff options
context:
space:
mode:
authorMohammed Hawari <mohammed@hawari.fr>2021-03-18 12:02:08 +0100
committerFlorin Coras <florin.coras@gmail.com>2021-03-18 16:35:32 +0000
commit34c54dff5c66f9a4aef77daf08219301e15cc1fa (patch)
tree622dcfcedbd679e4ffed8278713374c7e2183f8b /src/plugins/dpdk/device/init.c
parentaa7a2a1f32c9a91ea1ba04aa661b6ccddac2a79f (diff)
dpdk: don't mask interrupts for some drivers
It is well known that for some NICs, masking interrupts results in delaying desc writebacks, which breaks poll mode. This fix introduces an "int-unmaskable" dpdk device flag to identify such devices (typically Intel FVL). For such devices, interrupts are masked by a call to file_update(...,UNIX_FILE_UPDATE_DELETE) instead of rte_eth_dev_rx_intr_disable (...) Change-Id: Ifbc701aebe8572319b7aae19382bd683a47fc3cf Type: fix Fixes: 19ff0c3699342b512c03362b3815df684a661f49 Signed-off-by: Mohammed Hawari <mohammed@hawari.fr>
Diffstat (limited to 'src/plugins/dpdk/device/init.c')
-rw-r--r--src/plugins/dpdk/device/init.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/plugins/dpdk/device/init.c b/src/plugins/dpdk/device/init.c
index 78374af4b0f..bf1683b2096 100644
--- a/src/plugins/dpdk/device/init.c
+++ b/src/plugins/dpdk/device/init.c
@@ -448,10 +448,11 @@ dpdk_lib_init (dpdk_main_t * dm)
switch (xd->pmd)
{
/* Drivers with valid speed_capa set */
+ case VNET_DPDK_PMD_I40E:
+ xd->flags |= DPDK_DEVICE_FLAG_INT_UNMASKABLE;
case VNET_DPDK_PMD_E1000EM:
case VNET_DPDK_PMD_IGB:
case VNET_DPDK_PMD_IXGBE:
- case VNET_DPDK_PMD_I40E:
case VNET_DPDK_PMD_ICE:
xd->port_type = port_type_from_speed_capa (&dev_info);
xd->supported_flow_actions = VNET_FLOW_ACTION_MARK |
@@ -471,7 +472,6 @@ dpdk_lib_init (dpdk_main_t * dm)
}
xd->port_conf.intr_conf.rxq = 1;
-
break;
case VNET_DPDK_PMD_CXGBE:
case VNET_DPDK_PMD_MLX4:
@@ -482,9 +482,10 @@ dpdk_lib_init (dpdk_main_t * dm)
break;
/* SR-IOV VFs */
+ case VNET_DPDK_PMD_I40EVF:
+ xd->flags |= DPDK_DEVICE_FLAG_INT_UNMASKABLE;
case VNET_DPDK_PMD_IGBVF:
case VNET_DPDK_PMD_IXGBEVF:
- case VNET_DPDK_PMD_I40EVF:
xd->port_type = VNET_DPDK_PORT_TYPE_ETH_VF;
if (dm->conf->no_tx_checksum_offload == 0)
{
@@ -494,12 +495,14 @@ dpdk_lib_init (dpdk_main_t * dm)
DPDK_DEVICE_FLAG_TX_OFFLOAD |
DPDK_DEVICE_FLAG_INTEL_PHDR_CKSUM;
}
- /*xd->port_conf.intr_conf.rxq = 1;*/
+ /* sDPDK bug in multiqueue... */
+ /* xd->port_conf.intr_conf.rxq = 1; */
break;
/* iAVF */
case VNET_DPDK_PMD_IAVF:
- xd->port_type = VNET_DPDK_PORT_TYPE_ETH_VF;
+ xd->flags |= DPDK_DEVICE_FLAG_INT_UNMASKABLE;
+ xd->port_type = VNET_DPDK_PORT_TYPE_ETH_VF;
xd->supported_flow_actions = VNET_FLOW_ACTION_MARK |
VNET_FLOW_ACTION_REDIRECT_TO_NODE |
VNET_FLOW_ACTION_REDIRECT_TO_QUEUE |