From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out3-smtp.messagingengine.com (out3-smtp.messagingengine.com [66.111.4.27]) by dpdk.org (Postfix) with ESMTP id D73051B1F2 for ; Wed, 3 Oct 2018 21:40:50 +0200 (CEST) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 7E85321F21; Wed, 3 Oct 2018 15:40:50 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Wed, 03 Oct 2018 15:40:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; s=mesmtp; bh=Qe+CQ94f6phz2ARP/L6o4Kg yUeOHfpmC6zWxYuadlA4=; b=oMcw0i3hLhP+hO0dcLtBXgWZUVtnojCs4u52K7p g4qeZl0Pl4+MWyRc9osUAOcXfsXfCSEMX9wE3T5BdsQC9EtTvB6yDJTGIt2BzJft IbO/iQQkiF8KMDEnbTB4xGujg+tZOyS39sP27REW0kRVHLnxK26qtEgJodxpJRX1 eUeI= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:date:from :message-id:mime-version:subject:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=Qe+CQ94f6phz2ARP/ L6o4KgyUeOHfpmC6zWxYuadlA4=; b=YFHseDiIFIgiaZ/Fr3ezN7b+7tVu5nrjZ yeGzfjcsc/KhmIKWD33OUrZTb4bsiZK+K/a1wYngCPwPVvBjsv8vQGSGN5S4AnJf lotKgSib2ZhpNb9jtL5UFYHIgybQi+ukDFfW/ICbUvMz6NDUh8lNLrIXcTjf+w8d X07DG77S9uKWj8VO8AoYmK1MFjIToT7FfrDDcajSjoHY3a85g6aPSw7/kv6ao5Dg XCyLrhllj31RiQLUehLdJ6XPbveoqER8jnK3pNk7bUMW7lcO3ce/0Q9MdvLNtDL9 00M30VaOvQkWqW5+QWirmnrxNWH1t2gCC8Hg8j9rDaaxiAx9a5aFQ== X-ME-Sender: X-ME-Proxy: Received: from xps.monjalon.net (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 3E28D102DE; Wed, 3 Oct 2018 15:40:49 -0400 (EDT) From: Thomas Monjalon To: gaetan.rivet@6wind.com Cc: dev@dpdk.org Date: Wed, 3 Oct 2018 21:40:38 +0200 Message-Id: <20181003194039.7202-1-thomas@monjalon.net> X-Mailer: git-send-email 2.19.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH 1/2] bus/pci: rename devargs parameter id to addr 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: Wed, 03 Oct 2018 19:40:51 -0000 We could match devices by their PCI id (vendor id, device id, etc). But for now, only matching by PCI address is implemented. The devargs parameter "id" is renamed "addr" to reflect its real meaning. Signed-off-by: Thomas Monjalon --- drivers/bus/pci/pci_params.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/bus/pci/pci_params.c b/drivers/bus/pci/pci_params.c index 7630d4845..77b722ba9 100644 --- a/drivers/bus/pci/pci_params.c +++ b/drivers/bus/pci/pci_params.c @@ -12,12 +12,12 @@ #include "private.h" enum pci_params { - RTE_PCI_PARAMS_ID, + RTE_PCI_PARAMS_ADDR, RTE_PCI_PARAMS_MAX, }; static const char * const pci_params_keys[] = { - [RTE_PCI_PARAMS_ID] = "id", + [RTE_PCI_PARAMS_ADDR] = "addr", [RTE_PCI_PARAMS_MAX] = NULL, }; @@ -47,7 +47,7 @@ pci_dev_match(const struct rte_device *dev, return 0; pdev = RTE_DEV_TO_PCI_CONST(dev); /* if any field does not match. */ - if (rte_kvargs_process(kvlist, "id", + if (rte_kvargs_process(kvlist, pci_params_keys[RTE_PCI_PARAMS_ADDR], &pci_addr_kv_cmp, (void *)(intptr_t)&pdev->addr)) return 1; -- 2.19.0