Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp10416702ybi; Wed, 24 Jul 2019 22:50:35 -0700 (PDT) X-Google-Smtp-Source: APXvYqwL9p51uT2o+QThXdrsGy8T9k8049WufhZdgjAhEaTYUKoylVWFQOTBo6eXKd3kn7FNqQev X-Received: by 2002:a62:4d85:: with SMTP id a127mr14965628pfb.148.1564033835785; Wed, 24 Jul 2019 22:50:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564033835; cv=none; d=google.com; s=arc-20160816; b=p4CFQxFOqL966ojYxIGtnum37dGqQ4+ep3w/KfB1KdwhxFSkihBpm9/k2op+S1s0Pz NNp12O4MRoTNNsKtTLoDV8YhDnqyriwS8xjl7EFP/nUpeKixWLBv4c8eHNlK84FF9f0i 4hpXgwgQXgLfCdsdP8DWui7bxwFn3RZWm5nO5CoeqWeUbZcNzm/GztHXcSvf+DKtmbQX 7IKo7bDsDW5yD2lnBkE+djsngj3XwpJG74g2KPIilBPA//CqfwMQ+MQM722PMdogc0U+ 7EJbDGVn7cznPRirNqW05svqAqI8mvKvM50a6Qm8M6WD8v/KMTkYDfVcWiMgM19E0T5U Og6Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=+nfQZ2UdcSDgJjCDwmD/o1yYou6zHrnlrDckfQLhv48=; b=pFfd6RDCz6krTkTdZPea+iQqK8F+pESl1lJR0wTo54RAi9P0PAUFm5fC4h9/AJcdun 2QWEkYjHO4yJdWDjLPIIBgRMNkK2/ggotbZFb8oOyX7LcF7laxNsQydJczd0Gmw4osmH WXodB3GS669E1/hLrP5B/XTZGHw8IWBzPOEmNcvhPGhGbz3OZNgClDjdGzQFcpRAHPam XPSgeNB/j705KxJeyJ3++Kq/QsmWDMF4T7MbYFNyWe5EPTeTj+YXtBCoasXVIQF3pN5I VORVac1q9AacvdSLM5O1upQRs/WIVKWbD2kQ+9tdOrCSCNEXq9wb/J4UaQaztA+akY9T 2O8Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=CZB+qQZ+; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r26si16085428pgv.189.2019.07.24.22.50.19; Wed, 24 Jul 2019 22:50:35 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=CZB+qQZ+; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729795AbfGXXjr (ORCPT + 99 others); Wed, 24 Jul 2019 19:39:47 -0400 Received: from mail-io1-f68.google.com ([209.85.166.68]:36553 "EHLO mail-io1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388748AbfGXXjg (ORCPT ); Wed, 24 Jul 2019 19:39:36 -0400 Received: by mail-io1-f68.google.com with SMTP id o9so93396958iom.3; Wed, 24 Jul 2019 16:39:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=+nfQZ2UdcSDgJjCDwmD/o1yYou6zHrnlrDckfQLhv48=; b=CZB+qQZ+IiCjqbrl3pG1VgfoIKlT1esq374rHCiwoSTr+htDGMMdB25C4Kju1ptnOv Sr0vWDqL1QJ8UxaHm3MSMXR8LZpxI8sSOFGwYpaXvbXoOaNpfJfY+8QnxMoy0sD4c5/G 7qLcwiTTCg8VwoMBVrIn2Jjo3NIsaxQZU8ASK/EaGVoGZtibG80it6wU6C6lktP9f5Wt sSCIM70yBh8fL8rsrpffoHwj93kjzxv/1zN/Cv647ellh7AJiCG/dPXcCrWpJSP8U2lB tHP4E6gWavTvF+TOL0eTMooXt7XVQ3+ITlWaQuZTNGAIlCyXmIDsZO5E36ET0q1faLPK qv/A== 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:mime-version:content-transfer-encoding; bh=+nfQZ2UdcSDgJjCDwmD/o1yYou6zHrnlrDckfQLhv48=; b=e58DkMqClxTc58FKiC/JFu66D9+cu1JIlmjyhUx7aVSQkUjUzx67el+kxWbQkVBQIC 9dk3PMHKCNh70H1O6HutfvEddBbxaoY9tODg0+jnJR7/eswAmFsnGY6sj7IooZITmlJb jhit1cc/nHkRWA8AA/vCp8twUEvJcv0WjbDvjJmf6Ux3ZJ+yQJsZCSJyc15M4vbRsCVl OmiFC3nMBhoAxj3x8b+9hzsEKurUH8O7p+IR0XOFVh11iUu4ycxHgsdDY1/UXRy1XNWw rZAOyvbcOlCk3c4RwUiz1dtEAziYvgQDuOqlYBeJ514NrGkrm5lem5GyHawndpI48gvY fbAg== X-Gm-Message-State: APjAAAXNl8uQVG3bnhjntXOZv8PDKNd64pv7MoeTrtbb1ZKUTJgynSIT s/dl7QhvLjrifNap4V+MMhU= X-Received: by 2002:a6b:2cc7:: with SMTP id s190mr80038806ios.164.1564011576172; Wed, 24 Jul 2019 16:39:36 -0700 (PDT) Received: from localhost.localdomain (c-73-243-191-173.hsd1.co.comcast.net. [73.243.191.173]) by smtp.gmail.com with ESMTPSA id b14sm51612959iod.33.2019.07.24.16.39.34 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Wed, 24 Jul 2019 16:39:35 -0700 (PDT) From: Kelsey Skunberg To: bhelgaas@google.com, linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org Cc: skunberg.kelsey@gmail.com, linux-kernel-mentees@lists.linuxfoundation.org, skhan@linuxfoundation.org Subject: [PATCH v2 11/11] PCI: Move pci_*_node() declarations to drivers/pci/pci.h Date: Wed, 24 Jul 2019 17:38:48 -0600 Message-Id: <20190724233848.73327-12-skunberg.kelsey@gmail.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190724233848.73327-1-skunberg.kelsey@gmail.com> References: <20190711222341.111556-1-skunberg.kelsey@gmail.com> <20190724233848.73327-1-skunberg.kelsey@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org pci_*_node() is only called from drivers/pci/. Since these declarations do not need to be visible to the rest of the kernel, move to drivers/pci/pci.h. Signed-off-by: Kelsey Skunberg --- drivers/pci/pci.h | 9 +++++++++ include/linux/pci.h | 8 -------- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/drivers/pci/pci.h b/drivers/pci/pci.h index 6cdc3500de15..27089a87dfea 100644 --- a/drivers/pci/pci.h +++ b/drivers/pci/pci.h @@ -592,6 +592,10 @@ struct device_node; int of_pci_parse_bus_range(struct device_node *node, struct resource *res); int of_get_pci_domain_nr(struct device_node *node); int of_pci_get_max_link_speed(struct device_node *node); +void pci_set_of_node(struct pci_dev *dev); +void pci_release_of_node(struct pci_dev *dev); +void pci_set_bus_of_node(struct pci_bus *bus); +void pci_release_bus_of_node(struct pci_bus *bus); #else static inline int @@ -611,6 +615,11 @@ of_pci_get_max_link_speed(struct device_node *node) { return -EINVAL; } + +static inline void pci_set_of_node(struct pci_dev *dev) { } +static inline void pci_release_of_node(struct pci_dev *dev) { } +static inline void pci_set_bus_of_node(struct pci_bus *bus) { } +static inline void pci_release_bus_of_node(struct pci_bus *bus) { } #endif /* CONFIG_OF */ #if defined(CONFIG_OF_ADDRESS) diff --git a/include/linux/pci.h b/include/linux/pci.h index a483b7598059..d354fbcee5a7 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -2264,10 +2264,6 @@ int pci_vpd_find_info_keyword(const u8 *buf, unsigned int off, #ifdef CONFIG_OF struct device_node; struct irq_domain; -void pci_set_of_node(struct pci_dev *dev); -void pci_release_of_node(struct pci_dev *dev); -void pci_set_bus_of_node(struct pci_bus *bus); -void pci_release_bus_of_node(struct pci_bus *bus); struct irq_domain *pci_host_bridge_of_msi_domain(struct pci_bus *bus); int pci_parse_request_of_pci_ranges(struct device *dev, struct list_head *resources, @@ -2277,10 +2273,6 @@ int pci_parse_request_of_pci_ranges(struct device *dev, struct device_node *pcibios_get_phb_of_node(struct pci_bus *bus); #else /* CONFIG_OF */ -static inline void pci_set_of_node(struct pci_dev *dev) { } -static inline void pci_release_of_node(struct pci_dev *dev) { } -static inline void pci_set_bus_of_node(struct pci_bus *bus) { } -static inline void pci_release_bus_of_node(struct pci_bus *bus) { } static inline struct irq_domain * pci_host_bridge_of_msi_domain(struct pci_bus *bus) { return NULL; } static inline int pci_parse_request_of_pci_ranges(struct device *dev, -- 2.20.1