From: Pablo de Lara Date: Thu, 11 Dec 2014 13:50:35 +0000 (+0000) Subject: app/test: fix multi-process when device is bound to uio X-Git-Tag: spdx-start~9931 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=3354dd7fef7d8acd03b68c754595e57897f93784;p=dpdk.git app/test: fix multi-process when device is bound to uio Since commit a155d4301 "support link bonding device initialization", EAL probes drivers to the PCI devices in rte_eal_init, then PCI resources are mapped if a device is bound to igb_uio driver, for instance. Therefore, test app probes all the devices and multiprocess unit test tries to map resources twice in the secondary processes, and test fails, caused by RTE_PCI_DRV_NEEDED_MAPPING flag in dummy pci driver my_driver2. Test is fixed by setting the driver flags to 0. Signed-off-by: Pablo de Lara --- diff --git a/app/test/test_pci.c b/app/test/test_pci.c index 4f0169a034..747d8b710f 100644 --- a/app/test/test_pci.c +++ b/app/test/test_pci.c @@ -64,11 +64,6 @@ static unsigned pci_dev_count; static int my_driver_init(struct rte_pci_driver *dr, struct rte_pci_device *dev); -/* - * To test cases where RTE_PCI_DRV_NEED_MAPPING is set, and isn't set, two - * drivers are created (one with IGB devices, the other with IXGBE devices). - */ - /* IXGBE NICS */ struct rte_pci_id my_driver_id[] = { @@ -92,7 +87,7 @@ struct rte_pci_driver my_driver = { .name = "test_driver", .devinit = my_driver_init, .id_table = my_driver_id, - .drv_flags = RTE_PCI_DRV_NEED_MAPPING, + .drv_flags = 0, }; struct rte_pci_driver my_driver2 = {