MCPcopy Create free account
hub / github.com/F-Stack/f-stack / iavf_dev_stop

Function iavf_dev_stop

dpdk/drivers/net/iavf/iavf_ethdev.c:1078–1109  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1076}
1077
1078static int
1079iavf_dev_stop(struct rte_eth_dev *dev)
1080{
1081 struct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(dev->data->dev_private);
1082 struct iavf_adapter *adapter =
1083 IAVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private);
1084 struct rte_intr_handle *intr_handle = dev->intr_handle;
1085
1086 PMD_INIT_FUNC_TRACE();
1087
1088 if (adapter->closed)
1089 return -1;
1090
1091 if (!(vf->vf_res->vf_cap_flags & VIRTCHNL_VF_OFFLOAD_WB_ON_ITR) &&
1092 dev->data->dev_conf.intr_conf.rxq != 0)
1093 rte_intr_disable(intr_handle);
1094
1095 if (adapter->stopped == 1)
1096 return 0;
1097
1098 /* Disable the interrupt for Rx */
1099 rte_intr_efd_disable(intr_handle);
1100 /* Rx interrupt vector mapping free */
1101 rte_intr_vec_list_free(intr_handle);
1102
1103 iavf_stop_queues(dev);
1104
1105 adapter->stopped = 1;
1106 dev->data->dev_started = 0;
1107
1108 return 0;
1109}
1110
1111static int
1112iavf_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)

Callers 1

iavf_dev_closeFunction · 0.85

Calls 4

rte_intr_vec_list_freeFunction · 0.85
iavf_stop_queuesFunction · 0.85
rte_intr_disableFunction · 0.50
rte_intr_efd_disableFunction · 0.50

Tested by

no test coverage detected