From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pg0-f67.google.com (mail-pg0-f67.google.com [74.125.83.67]) by dpdk.org (Postfix) with ESMTP id 380258E69 for ; Fri, 18 May 2018 01:45:07 +0200 (CEST) Received: by mail-pg0-f67.google.com with SMTP id c22-v6so1819671pgn.11 for ; Thu, 17 May 2018 16:45:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id; bh=oyx+641WAc//lgiJhNyzlYdOhzzXFyxYU90T4TLUAP8=; b=Af3KPqrK3XcBznBGhlYeHmDMF4CO9HWq9HkdiVFisENVkvciIM1lILHYXS/MVAtEe2 OWpb6kHQVStVzTj8w+ZS3DOCxY2t6+KNKGXwy7BFvrfu6dVtuRFkRr6KwjVWHVxI5Irl JOgw6/ceo6nKWOiDZycih3cCRcTxaJG3pl6xtqBKohtiykvIRU9hjUhm3gaWdXjQdSxc j2GwEsKEEPdXlVPKOAW8m84hbYFphfvX3stHTCZ2QTfFRiq5qikY70iqoohqYNWsP9us Fyj6GlQePygaeppQQCbZLdu75ssJjTOb0c6z6uioGQlwZITOpTKVha253sFzqT6OWGSV bITQ== 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; bh=oyx+641WAc//lgiJhNyzlYdOhzzXFyxYU90T4TLUAP8=; b=YyWoclVtmlR7kqu0NhUdwPVf3xDLINGn5rFaHAMJlIFEi5TX3K13yQcIIrZnowDgB6 nXr0WU0tmBPHinfY8QD8TghwPXUutZCv1n9RQlT/+cl8NHMXiOntssiGnLXgqlD1VI1H hsUg8C/juHoLVSeu7/GJzyskUyYIA2zw9KGhSGZvGvpOSJ9z7Dcur1yVsTQO8APkFKUO BC8gQLW4aEPYRvi7W27KCtzHnrrIOGQnVOeqIY1ewxgxmZ2uYfib6GPZ2QzyK+LnF6Ei GjLwsjC9Pw27zbPkc8HDfbr2s2TJ4z4t1K3gtkb3ph4aH8nW/Bsaj+xUNQCpfQogjm0u wRfQ== X-Gm-Message-State: ALKqPwfpKlIjkTcezCcHOEmX5iLzDJ3VvxBITxnv8C0NjL4NFA4+Ujv5 bFMnmQ2yZ6gc9KmGyUqRJPvBQX4YsdE= X-Google-Smtp-Source: AB8JxZrhkRXZQo5C1ZLmafiS7eEgbK+bTbyQDrhtXLeuFjej59+XUF+KaI6KixlEwjBTnHqoksI/oA== X-Received: by 2002:a65:66d7:: with SMTP id c23-v6mr655891pgw.76.1526600706086; Thu, 17 May 2018 16:45:06 -0700 (PDT) Received: from xeon-e3.lan (204-195-35-107.wavecable.com. [204.195.35.107]) by smtp.gmail.com with ESMTPSA id b28-v6sm14623009pfl.168.2018.05.17.16.45.05 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 17 May 2018 16:45:05 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Date: Thu, 17 May 2018 16:44:58 -0700 Message-Id: <20180517234458.5602-1-stephen@networkplumber.org> X-Mailer: git-send-email 2.17.0 Subject: [dpdk-dev] [PATCH] pci: remove unused function 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, 17 May 2018 23:45:07 -0000 The function rte_pci_probe_one is private to PCI and is not used anywhere in current code base. Remove dead code. Signed-off-by: Stephen Hemminger --- drivers/bus/pci/pci_common.c | 38 ------------------------------------ drivers/bus/pci/private.h | 15 -------------- 2 files changed, 53 deletions(-) diff --git a/drivers/bus/pci/pci_common.c b/drivers/bus/pci/pci_common.c index 7215aaec3add..3d21d7373b60 100644 --- a/drivers/bus/pci/pci_common.c +++ b/drivers/bus/pci/pci_common.c @@ -254,44 +254,6 @@ pci_probe_all_drivers(struct rte_pci_device *dev) return 1; } -/* - * Find the pci device specified by pci address, then invoke probe function of - * the driver of the device. - */ -int -rte_pci_probe_one(const struct rte_pci_addr *addr) -{ - struct rte_pci_device *dev = NULL; - - int ret = 0; - - if (addr == NULL) - return -1; - - /* update current pci device in global list, kernel bindings might have - * changed since last time we looked at it. - */ - if (pci_update_device(addr) < 0) - goto err_return; - - FOREACH_DEVICE_ON_PCIBUS(dev) { - if (rte_pci_addr_cmp(&dev->addr, addr)) - continue; - - ret = pci_probe_all_drivers(dev); - if (ret) - goto err_return; - return 0; - } - return -1; - -err_return: - RTE_LOG(WARNING, EAL, - "Requested device " PCI_PRI_FMT " cannot be used\n", - addr->domain, addr->bus, addr->devid, addr->function); - return -1; -} - /* * Detach device specified by its pci address. */ diff --git a/drivers/bus/pci/private.h b/drivers/bus/pci/private.h index 88fa587e74dc..748abb6617fe 100644 --- a/drivers/bus/pci/private.h +++ b/drivers/bus/pci/private.h @@ -32,21 +32,6 @@ rte_pci_probe(void); */ int rte_pci_scan(void); -/** - * Probe the single PCI device. - * - * Scan the content of the PCI bus, and find the pci device specified by pci - * address, then call the probe() function for registered driver that has a - * matching entry in its id_table for discovered device. - * - * @param addr - * The PCI Bus-Device-Function address to probe. - * @return - * - 0 on success. - * - Negative on error. - */ -int rte_pci_probe_one(const struct rte_pci_addr *addr); - /** * Close the single PCI device. * -- 2.17.0