From mboxrd@z Thu Jan 1 00:00:00 1970 From: Aaron Conole Subject: [PATCH v5 25/26] eal: do not panic on failed bus scan Date: Mon, 27 Feb 2017 11:18:10 -0500 Message-ID: <20170227161811.12309-26-aconole@redhat.com> References: <20170225160309.31270-1-aconole@redhat.com> <20170227161811.12309-1-aconole@redhat.com> Cc: Stephen Hemminger , Bruce Richardson To: dev@dpdk.org Return-path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id 441AEBD2A for ; Mon, 27 Feb 2017 17:18:27 +0100 (CET) In-Reply-To: <20170227161811.12309-1-aconole@redhat.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" For now, do an abort. It's likely that even aborting the initialization is premature in this case, as it may be possible to proceed even if one bus or another is not available. Signed-off-by: Aaron Conole --- lib/librte_eal/linuxapp/eal/eal.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/librte_eal/linuxapp/eal/eal.c b/lib/librte_eal/linuxapp/eal/eal.c index 361256f..77f0d24 100644 --- a/lib/librte_eal/linuxapp/eal/eal.c +++ b/lib/librte_eal/linuxapp/eal/eal.c @@ -899,8 +899,11 @@ rte_eal_init(int argc, char **argv) return -1; } - if (rte_bus_scan()) - rte_panic("Cannot scan the buses for devices\n"); + if (rte_bus_scan()) { + RTE_LOG(ERR, EAL, "Cannot scan the buses for devices\n"); + rte_errno = ENODEV; + return -1; + } RTE_LCORE_FOREACH_SLAVE(i) { -- 2.9.3