From ddc5d282fb02cabb3652b250e35606074818aac8 Mon Sep 17 00:00:00 2001 From: Huawei Xie Date: Tue, 8 Mar 2016 23:33:38 +0800 Subject: [PATCH] pci: fix error code comment positive return of devinit of pci driver means the driver doesn't support this device. Signed-off-by: Huawei Xie Acked-by: Yuanhan Liu Acked-by: David Marchand --- lib/librte_eal/common/eal_common_pci.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/librte_eal/common/eal_common_pci.c b/lib/librte_eal/common/eal_common_pci.c index 366fb46e5d..40f4922904 100644 --- a/lib/librte_eal/common/eal_common_pci.c +++ b/lib/librte_eal/common/eal_common_pci.c @@ -197,7 +197,7 @@ rte_eal_pci_probe_one_driver(struct rte_pci_driver *dr, struct rte_pci_device *d /* call the driver devinit() function */ return dr->devinit(dr, dev); } - /* return positive value if driver is not found */ + /* return positive value if driver doesn't support this device */ return 1; } @@ -252,7 +252,7 @@ rte_eal_pci_detach_dev(struct rte_pci_driver *dr, return 0; } - /* return positive value if driver is not found */ + /* return positive value if driver doesn't support this device */ return 1; } @@ -276,7 +276,7 @@ pci_probe_all_drivers(struct rte_pci_device *dev) /* negative value is an error */ return -1; if (rc > 0) - /* positive value means driver not found */ + /* positive value means driver doesn't support it */ continue; return 0; } @@ -303,7 +303,7 @@ pci_detach_all_drivers(struct rte_pci_device *dev) /* negative value is an error */ return -1; if (rc > 0) - /* positive value means driver not found */ + /* positive value means driver doesn't support it */ continue; return 0; } -- 2.20.1