From patchwork Tue Jun 28 07:54:01 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomasz Nowicki X-Patchwork-Id: 9202241 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 D55B16074E for ; Tue, 28 Jun 2016 07:57:14 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C59F82837F for ; Tue, 28 Jun 2016 07:57:14 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B9515285E7; Tue, 28 Jun 2016 07:57:14 +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=-4.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 583A22837F for ; Tue, 28 Jun 2016 07:57:14 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.85_2 #1 (Red Hat Linux)) id 1bHns8-0002iJ-HB; Tue, 28 Jun 2016 07:55:52 +0000 Received: from mail-lf0-x22c.google.com ([2a00:1450:4010:c07::22c]) by bombadil.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1bHnrC-0000lj-LD for linux-arm-kernel@lists.infradead.org; Tue, 28 Jun 2016 07:54:55 +0000 Received: by mail-lf0-x22c.google.com with SMTP id f6so5562585lfg.0 for ; Tue, 28 Jun 2016 00:54:34 -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=j62y8kMgPw56QB5nMFpnxu1XnaTFcBOdDkwNUWg8D74=; b=CQZzqwFPSwi8rKqTAqt630VhIJtJCgemH5NRjJol0hO2tAiY3YKRIS6UjMFWGxrjp0 /SJiJWfjM+WyPF8bZcnECeRKCqTdUXkrkbkfaQU1wsXWiwbMtqLr87aC5A/E5V5KCekb zs2L2QgTsNAv+E+VV44ayK9Q69i7TlQIeXTgTCQCssPTpOhFkDTKt6BKnJKPtnLHAnXo Il0SKxnLptrXSEP4ocebzquReVivkW7fHnXD0JB1bXo4qxWyXKhgiG/Wk1iBvpDnhl5c YuOgl18WwNwq0d1zHNEp/TJGVzVTGtrtKnh2OQ2KBJPPPUqHaQXP11PreMbOnoaFqPP8 gQ3w== 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=j62y8kMgPw56QB5nMFpnxu1XnaTFcBOdDkwNUWg8D74=; b=jXbm6rSUF57eT2jUneiqdrCm6g2xNjHh8Eois6cnnv7U52NgAuXigEqhq0MtBu6jn/ E86F2gl7E1KF3mDW3Owsr17giAYlSzaXv7BGE8jtW8AAMfOIyQLD/B8MM/jbaYRjFhYN PtmOgSo9aD1GNuB0WssCuc6gzlPBEBve2mQ/ktLxLLSwTzn3LwYU7yw3cJCLTVNo4PSM tCoSB+DTO3hZKv9uNn3cBqpwWvSHzWV2nAVOnCajAb3VIeddyPCcNSlgfM2hsvIaN7hA +y4nzCs5Pz41jhzG2ADSz02splLK1nAw1pdZgweM+RP4bFCz8WLW2s79PG++IgsppJoI ND+A== X-Gm-Message-State: ALyK8tJTdpBsKYfmWUFKc35Lzay/FrtQjdsW+2R8OcC5UuhZRluXvjJocn4t0WC6XdFN6w== X-Received: by 10.46.9.215 with SMTP id 206mr486482ljj.63.1467100472637; Tue, 28 Jun 2016 00:54:32 -0700 (PDT) Received: from tn-HP-4.semihalf.local (31-172-191-173.noc.fibertech.net.pl. [31.172.191.173]) by smtp.gmail.com with ESMTPSA id f66sm3856201lji.13.2016.06.28.00.54.29 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 28 Jun 2016 00:54:31 -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 Subject: [RFC PATCH v4 4/5] ARM64/PCI: Start using quirks handling for ACPI based PCI host controller Date: Tue, 28 Jun 2016 09:54:01 +0200 Message-Id: <1467100442-28078-5-git-send-email-tn@semihalf.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1467100442-28078-1-git-send-email-tn@semihalf.com> References: <1467100442-28078-1-git-send-email-tn@semihalf.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160628_005455_027821_C307FFC3 X-CRM114-Status: GOOD ( 10.97 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jcm@redhat.com, gabriele.paoloni@huawei.com, linaro-acpi@lists.linaro.org, jhugo@codeaurora.org, linux-pci@vger.kernel.org, dhdang@apm.com, Liviu.Dudau@arm.com, ddaney@caviumnetworks.com, jeremy.linton@arm.com, linux-kernel@vger.kernel.org, linux-acpi@vger.kernel.org, robert.richter@caviumnetworks.com, cov@codeaurora.org, liudongdong3@huawei.com, msalter@redhat.com, wangyijing@huawei.com, Tomasz Nowicki , mw@semihalf.com, andrea.gallo@linaro.org, linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Since there are platforms which have non-compliant ECAM space we need to override these accessors prior to PCI buses enumeration. In order to do that we call pci_mcfg_match_quirks() to retrieve custom pci_config_window structure. If no correlated quirk on list, use fully ECAM compliant generic PCI config accessors. Signed-off-by: Tomasz Nowicki --- arch/arm64/kernel/pci.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/arm64/kernel/pci.c b/arch/arm64/kernel/pci.c index addf00c..ef142b8 100644 --- a/arch/arm64/kernel/pci.c +++ b/arch/arm64/kernel/pci.c @@ -152,8 +152,7 @@ struct pci_bus *pci_acpi_scan_root(struct acpi_pci_root *root) if (!ri) return NULL; - ri->cfg = pci_acpi_setup_ecam_mapping(root, - &pci_generic_ecam_ops.pci_ops); + ri->cfg = pci_mcfg_match_quirks(root); if (!ri->cfg) { kfree(ri); return NULL;