From patchwork Wed Apr 26 10:06:17 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lorenzo Pieralisi X-Patchwork-Id: 9700889 X-Patchwork-Delegate: bhelgaas@google.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id CB6EF60245 for ; Wed, 26 Apr 2017 10:05:39 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A5C33285EA for ; Wed, 26 Apr 2017 10:05:39 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9A81A285EC; Wed, 26 Apr 2017 10:05:39 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 560EC285EA for ; Wed, 26 Apr 2017 10:05:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1955050AbdDZKFf (ORCPT ); Wed, 26 Apr 2017 06:05:35 -0400 Received: from foss.arm.com ([217.140.101.70]:52648 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1034752AbdDZKFf (ORCPT ); Wed, 26 Apr 2017 06:05:35 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 5F5E215A1; Wed, 26 Apr 2017 03:05:34 -0700 (PDT) Received: from red-moon.cambridge.arm.com (red-moon.cambridge.arm.com [10.1.206.55]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 37C3B3F3E1; Wed, 26 Apr 2017 03:05:33 -0700 (PDT) From: Lorenzo Pieralisi To: linux-pci@vger.kernel.org Cc: linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, Lorenzo Pieralisi , Bjorn Helgaas , Sergey Temerkhanov , Sinan Kaya Subject: [RFC/RFT PATCH 1/3] PCI: Introduce pci_bus_find_numa_node() Date: Wed, 26 Apr 2017 11:06:17 +0100 Message-Id: <20170426100619.31758-1-lorenzo.pieralisi@arm.com> X-Mailer: git-send-email 2.10.0 Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Create an empty stub, to be populated by firmware methods, to retrieve the NUMA node for a given pci_bus. No functional change introduced. Signed-off-by: Lorenzo Pieralisi Cc: Bjorn Helgaas --- drivers/pci/pci.c | 6 ++++++ include/linux/pci.h | 1 + 2 files changed, 7 insertions(+) diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index 7904d02..2de9162 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c @@ -12,6 +12,7 @@ #include #include #include +#include #include #include #include @@ -5235,6 +5236,11 @@ int pci_bus_find_domain_nr(struct pci_bus *bus, struct device *parent) #endif #endif +int pci_bus_find_numa_node(struct pci_bus *bus) +{ + return NUMA_NO_NODE; +} + /** * pci_ext_cfg_avail - can we access extended PCI config space? * diff --git a/include/linux/pci.h b/include/linux/pci.h index eb3da1a..9e62462 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -1481,6 +1481,7 @@ static inline int acpi_pci_bus_find_domain_nr(struct pci_bus *bus) #endif int pci_bus_find_domain_nr(struct pci_bus *bus, struct device *parent); #endif +int pci_bus_find_numa_node(struct pci_bus *bus); /* some architectures require additional setup to direct VGA traffic */ typedef int (*arch_set_vga_state_t)(struct pci_dev *pdev, bool decode,