From patchwork Thu Mar 17 10:52:49 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 102551 Delivered-To: patch@linaro.org Received: by 10.112.199.169 with SMTP id jl9csp385403lbc; Thu, 17 Mar 2016 03:55:17 -0700 (PDT) X-Received: by 10.98.10.20 with SMTP id s20mr12997797pfi.109.1458212117268; Thu, 17 Mar 2016 03:55:17 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n62si1105290pfi.139.2016.03.17.03.55.16; Thu, 17 Mar 2016 03:55:17 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1030281AbcCQKzP (ORCPT + 31 others); Thu, 17 Mar 2016 06:55:15 -0400 Received: from mout.kundenserver.de ([217.72.192.73]:59612 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933112AbcCQKzM (ORCPT ); Thu, 17 Mar 2016 06:55:12 -0400 Received: from wuerfel.lan. ([78.42.132.4]) by mrelayeu.kundenserver.de (mreue101) with ESMTPA (Nemesis) id 0Lucy0-1ZgsQd3oLQ-00zrLD; Thu, 17 Mar 2016 11:54:36 +0100 From: Arnd Bergmann To: Russell King , Catalin Marinas , Will Deacon , Thomas Gleixner , Jason Cooper , Marc Zyngier , Bjorn Helgaas Cc: Arnd Bergmann , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org Subject: [PATCH] arm/arm64/irqchip/pci: select PCI_MSI instead of depending on it Date: Thu, 17 Mar 2016 11:52:49 +0100 Message-Id: <1458212069-896315-1-git-send-email-arnd@arndb.de> X-Mailer: git-send-email 2.7.0 X-Provags-ID: V03:K0:8u1V4EG8XwOlfI6XCYw1WThhhL1inDWTYaoAOw/Q+lw2Biqsi/J kDJwPt6oUHwX2RrSDUghwDJpIQ3K98VMyqxbNZBCXSOV1lxJfwtM5m0/rxnMAfxiEI2po+w j6QVEeIIF0ZLz314lHmyR3FxUbdyHE/qYumntRbFLQPaQPbl0Dwxz7wo92FStYnzIw+vMCs b4HQ4x32WsGUR3+nMZUxA== X-UI-Out-Filterresults: notjunk:1; V01:K0:tMQvdGK5uJs=:DMz9e0eYtUgrxWVVUQ9clX 0CKIJriw/WamUMYSi928aX1ec60NBG+m8peyFKL1g9fb4vKg1gE5s+Qp84c1SgkWLjQX3xnze owcjnJsuOdo80VNVa+FnqeiOC/+KQLG47Ly9O08pGd0OgHldwk9wDqh0ALUSzI3laVtRtrHpk Sx5eqtcZqfvZpdmdVw6plebUYILJQ0J9IsX0i+YyTp/5uuOWaTPYyplzn56Ny4sqmt9Ch3BkO REdL+IbWSeHMJmZuZ/ffB9CLUPrE0rLcGLxUGKfb7Qtdbd4li6krNGPEIpiiApssBqn548GO/ mZlhuZ27GiOmrIX8RN5CAO6Xd+ZWHlh9kMF9f2pVMuJ6eBHDHbdl3ieh4sS7rNQ6/AnRl2v1r VkEfcr+BCkfyznn5Fxmf8/RPSrQprrsLFggerPA2BGBv/oJr58c++Dy4GykExBkD+J6cWzFmm d3lTzBnuea9Tf3K3rYquvXqEzAYDD8k8LjxSYZexq8EorTL5RYKlhLv36VOOZSSfJYd8Yl28V mieqDqcA7EYe735o9Pp/cmvNybMhYZAnQKYIs+hlbJawhl6ARR4XPQB4eyLFNfmfdpUUqqhX1 EQnaVst/HG96mYL7Rsl+L/y7JkW0OpqVF3vLfFX88MHveEfy7VqKUovTZexlQwX5j8eWfbNm9 Kukjgwm4X3EboSqiPpZnBIlT3BOGVGfShwF+stoorbmUbXHNxXuz/DgkKeAAcUuNkvV8= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The PCI_MSI symbol is used inconsistently throughout the tree, with some drivers using 'select' and others using 'depends on', or using conditional selects. This keeps causing problems, and the latest one is a result of ARCH_ALPINE using a 'select' statement to enable its platform specific MSI driver but not enabling MSI support first: warning: (ARCH_ALPINE) selects ALPINE_MSI which has unmet direct dependencies (PCI && PCI_MSI) drivers/irqchip/irq-alpine-msi.c:104:15: error: variable 'alpine_msix_domain_info' has initializer but incomplete type static struct msi_domain_info alpine_msix_domain_info = { ^~~~~~~~~~~~~~~ drivers/irqchip/irq-alpine-msi.c:105:2: error: unknown field 'flags' specified in initializer .flags = MSI_FLAG_USE_DEF_DOM_OPS | MSI_FLAG_USE_DEF_CHIP_OPS | ^ drivers/irqchip/irq-alpine-msi.c:105:11: error: 'MSI_FLAG_USE_DEF_DOM_OPS' undeclared here (not in a function) .flags = MSI_FLAG_USE_DEF_DOM_OPS | MSI_FLAG_USE_DEF_CHIP_OPS | ^~~~~~~~~~~~~~~~~~~~~~~~ There is little reason to enable PCI support for a platform that uses MSI but then leaving MSI disabled at compile time, so this patch changes the various Kconfig statement relating to PCI_MSI so they all use 'select'. Signed-off-by: Arnd Bergmann Suggested-by: Marc Zyngier --- arch/arm/Kconfig | 3 ++- arch/arm64/Kconfig | 4 ++-- drivers/irqchip/Kconfig | 11 ++++++++--- drivers/pci/host/Kconfig | 10 ++++++---- 4 files changed, 18 insertions(+), 10 deletions(-) -- 2.7.0 diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index aa9f67a89620..1c4e38764f02 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -703,9 +703,10 @@ config ARCH_VIRT depends on ARCH_MULTI_V7 select ARM_AMBA select ARM_GIC - select ARM_GIC_V2M if PCI_MSI + select ARM_GIC_V2M select ARM_GIC_V3 select ARM_PSCI + select PCI select HAVE_ARM_ARCH_TIMER # diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig index 4f436220384f..c9a3161e0aed 100644 --- a/arch/arm64/Kconfig +++ b/arch/arm64/Kconfig @@ -19,9 +19,9 @@ config ARM64 select ARM_ARCH_TIMER select ARM_GIC select AUDIT_ARCH_COMPAT_GENERIC - select ARM_GIC_V2M if PCI_MSI + select ARM_GIC_V2M select ARM_GIC_V3 - select ARM_GIC_V3_ITS if PCI_MSI + select ARM_GIC_V3_ITS select ARM_PSCI_FW select BUILDTIME_EXTABLE_SORT select CLONE_BACKWARDS diff --git a/drivers/irqchip/Kconfig b/drivers/irqchip/Kconfig index 7e8c441ff2de..73ab0ecb9b3b 100644 --- a/drivers/irqchip/Kconfig +++ b/drivers/irqchip/Kconfig @@ -16,7 +16,8 @@ config ARM_GIC_MAX_NR config ARM_GIC_V2M bool depends on ARM_GIC - depends on PCI && PCI_MSI + depends on PCI + select PCI_MSI select PCI_MSI_IRQ_DOMAIN config GIC_NON_BANKED @@ -30,6 +31,8 @@ config ARM_GIC_V3 config ARM_GIC_V3_ITS bool + depends on PCI + select PCI_MSI select PCI_MSI_IRQ_DOMAIN config HISILICON_IRQ_MBIGEN @@ -63,11 +66,13 @@ config ARM_VIC_NR config ARMADA_370_XP_IRQ bool select GENERIC_IRQ_CHIP - select PCI_MSI_IRQ_DOMAIN if PCI_MSI + select PCI_MSI if PCI + select PCI_MSI_IRQ_DOMAIN if PCI config ALPINE_MSI bool - depends on PCI && PCI_MSI + depends on PCI + select PCI_MSI select GENERIC_IRQ_CHIP select PCI_MSI_IRQ_DOMAIN diff --git a/drivers/pci/host/Kconfig b/drivers/pci/host/Kconfig index c5014bf95a20..844d7eb79c45 100644 --- a/drivers/pci/host/Kconfig +++ b/drivers/pci/host/Kconfig @@ -118,7 +118,6 @@ config PCI_XGENE depends on ARCH_XGENE depends on OF select PCIEPORTBUS - select PCI_MSI_IRQ_DOMAIN if PCI_MSI help Say Y here if you want internal PCI support on APM X-Gene SoC. There are 5 internal PCIe ports available. Each port is GEN3 capable @@ -126,7 +125,9 @@ config PCI_XGENE config PCI_XGENE_MSI bool "X-Gene v1 PCIe MSI feature" - depends on PCI_XGENE && PCI_MSI + depends on PCI_XGENE + select PCI_MSI + select PCI_MSI_IRQ_DOMAIN default y help Say Y here if you want PCIe MSI support for the APM X-Gene v1 SoC. @@ -175,7 +176,7 @@ config PCIE_IPROC_BCMA config PCIE_IPROC_MSI bool "Broadcom iProc PCIe MSI support" depends on PCIE_IPROC_PLATFORM || PCIE_IPROC_BCMA - depends on PCI_MSI + select PCI_MSI select PCI_MSI_IRQ_DOMAIN default ARCH_BCM_IPROC help @@ -193,7 +194,8 @@ config PCIE_ALTERA config PCIE_ALTERA_MSI bool "Altera PCIe MSI feature" - depends on PCIE_ALTERA && PCI_MSI + depends on PCIE_ALTERA + select PCI_MSI select PCI_MSI_IRQ_DOMAIN help Say Y here if you want PCIe MSI support for the Altera FPGA.