#ifndef _RTE_ETHDEV_PCI_H_
#define _RTE_ETHDEV_PCI_H_
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#include <rte_malloc.h>
#include <rte_pci.h>
#include <rte_bus_pci.h>
return;
}
- eth_dev->intr_handle = &pci_dev->intr_handle;
+ eth_dev->intr_handle = pci_dev->intr_handle;
if (rte_eal_process_type() == RTE_PROC_PRIMARY) {
eth_dev->data->dev_flags = 0;
}
static inline int
-eth_dev_pci_specific_init(struct rte_eth_dev *eth_dev, void *bus_device) {
- struct rte_pci_device *pci_dev = bus_device;
+eth_dev_pci_specific_init(struct rte_eth_dev *eth_dev, void *bus_device)
+{
+ struct rte_pci_device *pci_dev = (struct rte_pci_device *)bus_device;
if (!pci_dev)
return -ENODEV;
return 0;
}
+#ifdef __cplusplus
+}
+#endif
+
#endif /* _RTE_ETHDEV_PCI_H_ */