From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f48.google.com (mail-wm0-f48.google.com [74.125.82.48]) by dpdk.org (Postfix) with ESMTP id 724ED1B1A6 for ; Thu, 12 Oct 2017 10:21:48 +0200 (CEST) Received: by mail-wm0-f48.google.com with SMTP id m72so10899274wmc.1 for ; Thu, 12 Oct 2017 01:21:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=px4Lm9Awh+8NfsH/mxf9hHxoKJG6VhhjA4K3sSsWDN0=; b=rkmalZkNXrEwshUhohZJZRjIQJ/D8DX7HAGogmdos9hZXfux2GKhbwWZ1GDAGaKpwm nS84yKnIjSzc0MfKvkDzBwt+1XPs6mRJSCk9n/tY+pJdwZH3sUoZlhwUkTHdlvKgW+Qa rrbAOZ2N2MvwMrTGdfZScDxdySPoNXjV2GfXOOxTsmk6E2RmZU3xgUUT0vhWWLrmTw1S 5tmfkjVr4z3Oa3rT5+xKe67/VslUwE9neU9uN8vDab8905HtsmNx9r/azqhru3+GIOiM G1WBocl+kWa8y5JLtwEOrjZwwwUiIJit/SRNHbHU0JrjAmC2AurgJOthQDLHYXR/+xno m8Xw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:in-reply-to:references; bh=px4Lm9Awh+8NfsH/mxf9hHxoKJG6VhhjA4K3sSsWDN0=; b=YcQkOdjBZCZuMs6gbmgydceOmRxuhV2JniNfkw71Ae94BaXYm5M2gRcynNiIO01nVm vSMbj0DSN0QmijmDE52pyeF9QyzGEaHYqZv04FclYPNMOEJQSO1vGaCvBi0eLC1Fsigt Ga5pPOp1+IV0CzAkSQy4B09dbjXL5QRzOkNdgtI9RaGKE2V46M1GhhJlnylYsZWg3hJi hUtG+fBve9a71dqR8YD7IVzx6S9fW5ki9I1nVg+5keXG+o7g4FSPAngUXRpIhINJVS5t FMefAYF0ZTdQmuiRIvbTaHxx4CeNlusZpgUdKoq6ToSt869Z4IDtMvrvxG5qlULsX0+V 6Apw== X-Gm-Message-State: AMCzsaVVN8iyGEdlDP6JA1u7stfmWm19T4AvCc7Dp0fgLE3sD2NG+s6M rTpCjjcSLNEvc5COw759+5s/35RY X-Google-Smtp-Source: AOwi7QDo3Q4XyXwDsbwKhxlKCdaZBX0hcdT8JEaCIU62fQs8ILLHgH9vNMFD0N5TDEm52MpFL2GD9Q== X-Received: by 10.223.198.82 with SMTP id u18mr1452420wrg.5.1507796507819; Thu, 12 Oct 2017 01:21:47 -0700 (PDT) Received: from bidouze.dev.6wind.com (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id 200sm19424728wmu.44.2017.10.12.01.21.46 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 12 Oct 2017 01:21:46 -0700 (PDT) From: Gaetan Rivet To: dev@dpdk.org Cc: Gaetan Rivet Date: Thu, 12 Oct 2017 10:21:13 +0200 Message-Id: <99b8b6774a8713ee8d64cf2e977919655c7393cf.1507796100.git.gaetan.rivet@6wind.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: References: In-Reply-To: References: Subject: [dpdk-dev] [PATCH v2 06/18] bus/pci: do not reference devargs list X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Oct 2017 08:21:48 -0000 This list should not be used by drivers. Use the public API instead. Signed-off-by: Gaetan Rivet --- drivers/bus/pci/pci_common.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/drivers/bus/pci/pci_common.c b/drivers/bus/pci/pci_common.c index 5fbcf11..0b64d20 100644 --- a/drivers/bus/pci/pci_common.c +++ b/drivers/bus/pci/pci_common.c @@ -75,12 +75,8 @@ static struct rte_devargs *pci_devargs_lookup(struct rte_pci_device *dev) { struct rte_devargs *devargs; struct rte_pci_addr addr; - struct rte_bus *pbus; - pbus = rte_bus_find_by_name("pci"); - TAILQ_FOREACH(devargs, &devargs_list, next) { - if (devargs->bus != pbus) - continue; + RTE_EAL_DEVARGS_FOREACH("pci", devargs) { devargs->bus->parse(devargs->name, &addr); if (!rte_eal_compare_pci_addr(&dev->addr, &addr)) return devargs; -- 2.1.4