From patchwork Tue May 10 15:20:00 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomasz Nowicki X-Patchwork-Id: 9059151 X-Patchwork-Delegate: bhelgaas@google.com Return-Path: X-Original-To: patchwork-linux-pci@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id BF5EBBF29F for ; Tue, 10 May 2016 15:21:12 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DD51E20154 for ; Tue, 10 May 2016 15:21:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id CE82F20148 for ; Tue, 10 May 2016 15:21:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753156AbcEJPVF (ORCPT ); Tue, 10 May 2016 11:21:05 -0400 Received: from mail-lf0-f50.google.com ([209.85.215.50]:35812 "EHLO mail-lf0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752589AbcEJPUW (ORCPT ); Tue, 10 May 2016 11:20:22 -0400 Received: by mail-lf0-f50.google.com with SMTP id j8so18704093lfd.2 for ; Tue, 10 May 2016 08:20:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=semihalf-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=oww6DiQTVAe+qg35KfMkGXPCAzuTFIIvw02PdtDW3Dw=; b=t09eDcvn2X9P1cBU0L+HADPtjqFURFyZeiYu1iAiYioXtCV12gPP3J8VG0chRMTiKC TCHLybUD8ElDn/wLiSlg9hZzENJ8BFVLDFfRvnYcLb3QUGeb4jWW6a+9C81jKrPSUizp Ch8i4fZOyPm500yQnWPrXTCY1XL1lCkpNKBnrejnO+TAQKuPFLJ4zPHPlzqj+EFpKPsy FUl/N3clDm5vMzcATvrvgdJ2Cku2Lk24OJbeG8yrMzS8Fy5FxfKlZm+gf8F/ueFZTGJ/ HDsJWBe3l+hwJRmw+r9luNl5b1UWh5XdnwDvMx6jT0yZMNg6u1k53ow1Qu4adQDgwc4j mMqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=oww6DiQTVAe+qg35KfMkGXPCAzuTFIIvw02PdtDW3Dw=; b=DN1xO4ecbk9U+iCvwLy0k0aiblEutjpoj8RENGzwvkZx45mZgtSnrnsnnT6nuTQ2xc vY01hJLMjx4CMsWT/B5I8xu/bHn1J5jrVlYijkt9Oo48Qs8kNHgBUnXrXs2S0kOlBN36 8UWFrJb12lu4LgY++2HkOlA10biFCoKBUacWr8K2kGs0NhH8syOO6UCBJqMsWFbgazZS ETV4PrQXtJN0Ovpmtx3yosBQN2gyaUAWr9ae8efWV7hehQ05Gl1GAQYGKAl6coA8xLRo XYxTOgni7LbvNCYNRuhS4cUFTAM2egQRaetxneW8z1bOsGo1R6M7F5lTRnqJRWGI/fIU cH1w== X-Gm-Message-State: AOPr4FV9SyVjhh/V/1fVxFvk9lFjH7FZBZAVU0QROwHbZaYbsdaC8eC0UjAVsr3i3JmE5g== X-Received: by 10.112.161.200 with SMTP id xu8mr18005195lbb.106.1462893615534; Tue, 10 May 2016 08:20:15 -0700 (PDT) Received: from tn-HP-4.semihalf.local (cardhu.semihalf.com. [213.17.239.108]) by smtp.gmail.com with ESMTPSA id s194sm468002lfs.40.2016.05.10.08.20.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 10 May 2016 08:20:14 -0700 (PDT) From: Tomasz Nowicki To: helgaas@kernel.org, arnd@arndb.de, will.deacon@arm.com, catalin.marinas@arm.com, rafael@kernel.org, hanjun.guo@linaro.org, Lorenzo.Pieralisi@arm.com, okaya@codeaurora.org, jchandra@broadcom.com Cc: robert.richter@caviumnetworks.com, mw@semihalf.com, Liviu.Dudau@arm.com, ddaney@caviumnetworks.com, wangyijing@huawei.com, Suravee.Suthikulpanit@amd.com, msalter@redhat.com, linux-pci@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, linaro-acpi@lists.linaro.org, jcm@redhat.com, andrea.gallo@linaro.org, dhdang@apm.com, jeremy.linton@arm.com, liudongdong3@huawei.com, cov@codeaurora.org, Tomasz Nowicki Subject: [PATCH V7 10/11] arm64, pci, acpi: Provide ACPI-specific prerequisites for PCI bus enumeration. Date: Tue, 10 May 2016 17:20:00 +0200 Message-Id: <1462893601-8937-11-git-send-email-tn@semihalf.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1462893601-8937-1-git-send-email-tn@semihalf.com> References: <1462893601-8937-1-git-send-email-tn@semihalf.com> Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org X-Spam-Status: No, score=-8.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP ACPI requires to run acpi_pci_{add|remove}_bus while new PCI bus is created. This allows to do some ACPI-specific additional configuration, like PCI hotplug slot enumeration. In order to fulfill these requirements, we implement arch-specific pcibios_{add|remove}_bus calls and call acpi_pci_{add|remove}_bus from there. Signed-off-by: Tomasz Nowicki To: Catalin Marinas To: Lorenzo Pieralisi To: Will Deacon To: Arnd Bergmann --- arch/arm64/kernel/pci.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/arch/arm64/kernel/pci.c b/arch/arm64/kernel/pci.c index 15109c11..eeec5f6 100644 --- a/arch/arm64/kernel/pci.c +++ b/arch/arm64/kernel/pci.c @@ -17,6 +17,7 @@ #include #include #include +#include #include /* @@ -64,6 +65,16 @@ int pcibios_alloc_irq(struct pci_dev *dev) return 0; } +void pcibios_add_bus(struct pci_bus *bus) +{ + acpi_pci_add_bus(bus); +} + +void pcibios_remove_bus(struct pci_bus *bus) +{ + acpi_pci_remove_bus(bus); +} + /* * raw_pci_read/write - Platform-specific PCI config space access. */