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

Function rte_event_dev_close

dpdk/lib/eventdev/rte_eventdev.c:1540–1560  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1538}
1539
1540int
1541rte_event_dev_close(uint8_t dev_id)
1542{
1543 struct rte_eventdev *dev;
1544
1545 RTE_EVENTDEV_VALID_DEVID_OR_ERR_RET(dev_id, -EINVAL);
1546 dev = &rte_eventdevs[dev_id];
1547 if (*dev->dev_ops->dev_close == NULL)
1548 return -ENOTSUP;
1549
1550 /* Device must be stopped before it can be closed */
1551 if (dev->data->dev_started == 1) {
1552 RTE_EDEV_LOG_ERR("Device %u must be stopped before closing",
1553 dev_id);
1554 return -EBUSY;
1555 }
1556
1557 event_dev_fp_ops_reset(rte_event_fp_ops + dev_id);
1558 rte_eventdev_trace_close(dev_id);
1559 return (*dev->dev_ops->dev_close)(dev);
1560}
1561
1562static inline int
1563eventdev_data_alloc(uint8_t dev_id, struct rte_eventdev_data **data,

Callers 15

rte_event_pmd_pci_removeFunction · 0.85
octeontx_dev_closeFunction · 0.85
cleanupFunction · 0.85
test_single_linkFunction · 0.85
test_info_getFunction · 0.85
cleanupFunction · 0.85
cleanupFunction · 0.85
testsuite_teardownFunction · 0.85
testsuite_teardownFunction · 0.85
testsuite_teardownFunction · 0.85

Calls 1

event_dev_fp_ops_resetFunction · 0.85

Tested by 15

cleanupFunction · 0.68
test_single_linkFunction · 0.68
test_info_getFunction · 0.68
cleanupFunction · 0.68
cleanupFunction · 0.68
testsuite_teardownFunction · 0.68
testsuite_teardownFunction · 0.68
testsuite_teardownFunction · 0.68
test_eventdev_closeFunction · 0.68
testsuite_teardownFunction · 0.68