From patchwork Tue Mar 31 15:24:22 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexander Chiang X-Patchwork-Id: 15427 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n2VFPf7D012361 for ; Tue, 31 Mar 2009 15:25:42 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1762529AbZCaPYZ (ORCPT ); Tue, 31 Mar 2009 11:24:25 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1762557AbZCaPYZ (ORCPT ); Tue, 31 Mar 2009 11:24:25 -0400 Received: from g4t0015.houston.hp.com ([15.201.24.18]:14595 "EHLO g4t0015.houston.hp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1762456AbZCaPYY (ORCPT ); Tue, 31 Mar 2009 11:24:24 -0400 Received: from smtp2.fc.hp.com (smtp.cnd.hp.com [15.11.136.114]) by g4t0015.houston.hp.com (Postfix) with ESMTP id E840A8A85; Tue, 31 Mar 2009 15:24:22 +0000 (UTC) Received: from localhost.localdomain (lart.fc.hp.com [15.11.146.31]) by smtp2.fc.hp.com (Postfix) with ESMTP id 2D6A92BD860; Tue, 31 Mar 2009 15:00:10 +0000 (UTC) Received: from bob.kio (localhost [127.0.0.1]) by localhost.localdomain (Postfix) with ESMTP id A58C426146; Tue, 31 Mar 2009 09:24:22 -0600 (MDT) Subject: [PATCH 15/15] PCI: remove deprecated pci_find_slot() interface To: jbarnes@virtuousgeek.org From: Alex Chiang Cc: linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org Date: Tue, 31 Mar 2009 09:24:22 -0600 Message-ID: <20090331152422.26622.85161.stgit@bob.kio> In-Reply-To: <20090331150158.26622.45423.stgit@bob.kio> References: <20090331150158.26622.45423.stgit@bob.kio> User-Agent: StGit/0.14.3.347.g594a MIME-Version: 1.0 Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org The last in-tree caller of pci_find_slot has been converted, so let's get rid of this deprecated interface. Signed-off-by: Alex Chiang --- drivers/pci/search.c | 30 ------------------------------ include/linux/pci.h | 8 -------- 2 files changed, 0 insertions(+), 38 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/pci/search.c b/drivers/pci/search.c index 5af8bd5..766d27a 100644 --- a/drivers/pci/search.c +++ b/drivers/pci/search.c @@ -115,36 +115,6 @@ pci_find_next_bus(const struct pci_bus *from) #ifdef CONFIG_PCI_LEGACY /** - * pci_find_slot - locate PCI device from a given PCI slot - * @bus: number of PCI bus on which desired PCI device resides - * @devfn: encodes number of PCI slot in which the desired PCI - * device resides and the logical device number within that slot - * in case of multi-function devices. - * - * Given a PCI bus and slot/function number, the desired PCI device - * is located in system global list of PCI devices. If the device - * is found, a pointer to its data structure is returned. If no - * device is found, %NULL is returned. - * - * NOTE: Do not use this function any more; use pci_get_slot() instead, as - * the PCI device returned by this function can disappear at any moment in - * time. - */ -struct pci_dev *pci_find_slot(unsigned int bus, unsigned int devfn) -{ - struct pci_dev *dev = NULL; - - while ((dev = pci_get_device(PCI_ANY_ID, PCI_ANY_ID, dev)) != NULL) { - if (dev->bus->number == bus && dev->devfn == devfn) { - pci_dev_put(dev); - return dev; - } - } - return NULL; -} -EXPORT_SYMBOL(pci_find_slot); - -/** * pci_find_device - begin or continue searching for a PCI device by vendor/device id * @vendor: PCI vendor id to match, or %PCI_ANY_ID to match all vendor ids * @device: PCI device id to match, or %PCI_ANY_ID to match all device ids diff --git a/include/linux/pci.h b/include/linux/pci.h index 7bd624b..cd42a55 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -574,8 +574,6 @@ extern void pci_sort_breadthfirst(void); struct pci_dev __deprecated *pci_find_device(unsigned int vendor, unsigned int device, struct pci_dev *from); -struct pci_dev __deprecated *pci_find_slot(unsigned int bus, - unsigned int devfn); #endif /* CONFIG_PCI_LEGACY */ enum pci_lost_interrupt_reason { @@ -895,12 +893,6 @@ static inline struct pci_dev *pci_find_device(unsigned int vendor, return NULL; } -static inline struct pci_dev *pci_find_slot(unsigned int bus, - unsigned int devfn) -{ - return NULL; -} - static inline struct pci_dev *pci_get_device(unsigned int vendor, unsigned int device, struct pci_dev *from)