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

Function zip_pci_remove

dpdk/drivers/compress/octeontx/otx_zip_pmd.c:672–694  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

670}
671
672static int
673zip_pci_remove(struct rte_pci_device *pci_dev)
674{
675 struct rte_compressdev *compressdev;
676 char compressdev_name[RTE_COMPRESSDEV_NAME_MAX_LEN];
677
678 if (pci_dev == NULL) {
679 ZIP_PMD_ERR(" Invalid PCI Device");
680 return -EINVAL;
681 }
682 rte_pci_device_name(&pci_dev->addr, compressdev_name,
683 sizeof(compressdev_name));
684
685 compressdev = rte_compressdev_pmd_get_named_dev(compressdev_name);
686 if (compressdev == NULL)
687 return -ENODEV;
688
689 if (rte_eal_process_type() == RTE_PROC_PRIMARY) {
690 if (zipvf_destroy(compressdev) < 0)
691 return -ENODEV;
692 }
693 return rte_compressdev_pmd_destroy(compressdev);
694}
695
696static struct rte_pci_id pci_id_octtx_zipvf_table[] = {
697 {

Callers

nothing calls this directly

Calls 5

rte_pci_device_nameFunction · 0.85
rte_eal_process_typeFunction · 0.85
zipvf_destroyFunction · 0.85

Tested by

no test coverage detected