From patchwork Fri Dec 20 03:54:13 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinath Mannam X-Patchwork-Id: 11304745 X-Patchwork-Delegate: lorenzo.pieralisi@arm.com Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 0590413A4 for ; Fri, 20 Dec 2019 03:54:42 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D833024682 for ; Fri, 20 Dec 2019 03:54:41 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b="cJaO9WZO" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727191AbfLTDyl (ORCPT ); Thu, 19 Dec 2019 22:54:41 -0500 Received: from mail-pg1-f194.google.com ([209.85.215.194]:34111 "EHLO mail-pg1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727084AbfLTDyk (ORCPT ); Thu, 19 Dec 2019 22:54:40 -0500 Received: by mail-pg1-f194.google.com with SMTP id r11so4273275pgf.1 for ; Thu, 19 Dec 2019 19:54:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=8eqGO3e+YlWd2ITnGshI//smKmblV0XTNcfdq+TYMgU=; b=cJaO9WZOkbkG7juQ89G9NsORAsUIiCXAkd3Q2MEokvMKStb/yDOkhlRNzU6TAvjN9S ZZrGniP+P94AL/GyIXY404p+00yENTXLFvIKxbFlsYS1APO/EVnySJYqR7anxdbnYnc9 Kdx9IMpug12jI35Wg6c6MSLATg9ifBJecQjxk= 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; bh=8eqGO3e+YlWd2ITnGshI//smKmblV0XTNcfdq+TYMgU=; b=so1F6OkGIcipWr1bfT0lvNSJCgGBRkPUmvWx1z0iSz7JxhB0wQ08fCixTWnh+tZncg hW6aPCsNH/FKacGmpz5DVV7udJMYqhN1gQxiJzJ2KBGCxDsxsa0qYK1/59u0dWGH7Qeo k4TcMaL/jEUpyh81qB+NhBSR+NjIa/QDvSqlSmhwTbzG5QMrq1VgOypOMrikQnAHCS2N eAkFDuZct/dE+LswWGoR+Un98072d82hsk1o/vIXtDGpU5kGbvRNstgegl89iJtltWCd FdqwCQmTyazWZHIZSJvGicgaWg4y7TXa8NMT3pvibm7d1iGVarsnigvSsyAj2wCOiWqC k44g== X-Gm-Message-State: APjAAAV453QbfgAs7/JrkOLFmOQQJIkb9FKNLy71YoKQpYJ6bLE19CtQ NAtGAvzj7Na0fINcHCT583Fbhw== X-Google-Smtp-Source: APXvYqzliOle0cHj6Nw6lZ4cm+lDLYjzQceDtMHClvbgwuNZNbZkk+N6zYQ+VXMfaRQ0BNa4fpD2vg== X-Received: by 2002:a63:cc4a:: with SMTP id q10mr12550840pgi.241.1576814079819; Thu, 19 Dec 2019 19:54:39 -0800 (PST) Received: from mannams-OptiPlex-7010.dhcp.broadcom.net ([192.19.234.250]) by smtp.gmail.com with ESMTPSA id t65sm10522205pfd.178.2019.12.19.19.54.35 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 19 Dec 2019 19:54:39 -0800 (PST) From: Srinath Mannam To: Lorenzo Pieralisi , Bjorn Helgaas , Florian Fainelli , Ray Jui , Rob Herring , Mark Rutland , Andy Shevchenko , Andrew Murray , Arnd Bergmann Cc: bcm-kernel-feedback-list@broadcom.com, linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Ray Jui , Srinath Mannam Subject: [PATCH v4 1/6] dt-bindings: pci: Update iProc PCI binding for INTx support Date: Fri, 20 Dec 2019 09:24:13 +0530 Message-Id: <1576814058-30003-2-git-send-email-srinath.mannam@broadcom.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1576814058-30003-1-git-send-email-srinath.mannam@broadcom.com> References: <1576814058-30003-1-git-send-email-srinath.mannam@broadcom.com> Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org From: Ray Jui Update the iProc PCIe binding document for better modeling of the legacy interrupt (INTx) support Signed-off-by: Ray Jui Signed-off-by: Srinath Mannam Reviewed-by: Rob Herring --- .../devicetree/bindings/pci/brcm,iproc-pcie.txt | 48 ++++++++++++++++++---- 1 file changed, 41 insertions(+), 7 deletions(-) diff --git a/Documentation/devicetree/bindings/pci/brcm,iproc-pcie.txt b/Documentation/devicetree/bindings/pci/brcm,iproc-pcie.txt index df065aa..d3f833a 100644 --- a/Documentation/devicetree/bindings/pci/brcm,iproc-pcie.txt +++ b/Documentation/devicetree/bindings/pci/brcm,iproc-pcie.txt @@ -13,9 +13,6 @@ controller, used in Stingray PAXB-based root complex is used for external endpoint devices. PAXC-based root complex is connected to emulated endpoint devices internal to the ASIC - reg: base address and length of the PCIe controller I/O register space -- #interrupt-cells: set to <1> -- interrupt-map-mask and interrupt-map, standard PCI properties to define the - mapping of the PCIe interface to interrupt numbers - linux,pci-domain: PCI domain ID. Should be unique for each host controller - bus-range: PCI bus numbers covered - #address-cells: set to <3> @@ -41,6 +38,21 @@ Required: - brcm,pcie-ob-axi-offset: The offset from the AXI address to the internal address used by the iProc PCIe core (not the PCIe address) +Legacy interrupt (INTx) support (optional): + +Note INTx is for PAXB only. +- interrupt-map-mask and interrupt-map, standard PCI properties to define +the mapping of the PCIe interface to interrupt numbers + +In addition, a sub-node that describes the legacy interrupt controller built +into the PCIe controller. +This sub-node must have the following properties: + - compatible: must be "brcm,iproc-intc" + - interrupt-controller: claims itself as an interrupt controller for INTx + - #interrupt-cells: set to <1> + - interrupts: interrupt line wired to the generic GIC for INTx support + - interrupt-parent: Phandle to the parent interrupt controller + MSI support (optional): For older platforms without MSI integrated in the GIC, iProc PCIe core provides @@ -77,8 +89,11 @@ Example: reg = <0x18012000 0x1000>; #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0>; - interrupt-map = <0 0 0 0 &gic GIC_SPI 100 IRQ_TYPE_NONE>; + interrupt-map-mask = <0 0 0 7>; + interrupt-map = <0 0 0 1 &pcie0_intc 0>, + <0 0 0 2 &pcie0_intc 1>, + <0 0 0 3 &pcie0_intc 2>, + <0 0 0 4 &pcie0_intc 3>; linux,pci-domain = <0>; @@ -98,6 +113,14 @@ Example: msi-parent = <&msi0>; + pcie0_intc: interrupt-controller { + compatible = "brcm,iproc-intc"; + interrupt-controller; + #interrupt-cells = <1>; + interrupt-parent = <&gic>; + interrupts = ; + }; + /* iProc event queue based MSI */ msi0: msi@18012000 { compatible = "brcm,iproc-msi"; @@ -115,8 +138,11 @@ Example: reg = <0x18013000 0x1000>; #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0>; - interrupt-map = <0 0 0 0 &gic GIC_SPI 106 IRQ_TYPE_NONE>; + interrupt-map-mask = <0 0 0 7>; + interrupt-map = <0 0 0 1 &pcie1_intc 0>, + <0 0 0 2 &pcie1_intc 1>, + <0 0 0 3 &pcie1_intc 2>, + <0 0 0 4 &pcie1_intc 3>; linux,pci-domain = <1>; @@ -130,4 +156,12 @@ Example: phys = <&phy 1 6>; phy-names = "pcie-phy"; + + pcie1_intc: interrupt-controller { + compatible = "brcm,iproc-intc"; + interrupt-controller; + #interrupt-cells = <1>; + interrupt-parent = <&gic>; + interrupts = ; + }; }; From patchwork Fri Dec 20 03:54:14 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinath Mannam X-Patchwork-Id: 11304747 X-Patchwork-Delegate: lorenzo.pieralisi@arm.com Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 8BCFD13A4 for ; Fri, 20 Dec 2019 03:54:49 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 6082224689 for ; Fri, 20 Dec 2019 03:54:49 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b="bNCUhLtJ" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727185AbfLTDys (ORCPT ); Thu, 19 Dec 2019 22:54:48 -0500 Received: from mail-pj1-f67.google.com ([209.85.216.67]:36878 "EHLO mail-pj1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727190AbfLTDyq (ORCPT ); Thu, 19 Dec 2019 22:54:46 -0500 Received: by mail-pj1-f67.google.com with SMTP id m13so3524659pjb.2 for ; Thu, 19 Dec 2019 19:54:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=AkOXN1U5p+FA8t9urRZFtx3Sofb7iv3pGbosqKjKqRs=; b=bNCUhLtJzwpphDO9+pjk73srA6q0wCM9ztvBg23x0X77leUP30sLTA3bAocQamoI0n XJ0oac8POFP6Lp+xQZ6knmalmt7ULbx+Rz84ghIkvLiIFdZ4NnK2ra6EjFMrB+ijfFB6 /Dsi3CK2XZqZj0MWSz+WiYH6ak3wqN2zTTVAE= 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; bh=AkOXN1U5p+FA8t9urRZFtx3Sofb7iv3pGbosqKjKqRs=; b=BGAJjBkEn0EmF6FhZaTdJQRG7V9Sdn5SuBFPFXg/MXCDMl/x7jNaBF2DkyaXxQsSLU 4a+TTXTk8izdRRPtndEsz2Y2x4gxgSZAwQKGQee/Fgh+wD3nZ8Q7dAn+rZAma0R9xeYm EHp7mqXuxUIhgWnIFZO7R81pIoY4BjXca7waE71OevdRQn9Uth/zhfs15XG8fIYa5zP4 jliLcbIB49oymkFzzVGR/SC3aXVfhHvnpt/6oUz5RbY73QmBQ9rLA/QBeR2XOsPlmk/J 1W1Uck0HNxyZ0mpTQ7WP9/8yLMwV/mmIl86iA1ZyGaceVYJbXZXKhGQt1FtItGg6h+Nu 4+Cg== X-Gm-Message-State: APjAAAWeUr2+mqMiBQ8W5JVEXklF8XzK6wrkmVyqIHYUWlWP7ACWee0T ZdwO0F/W/xpUEopuzl4vPIY95A== X-Google-Smtp-Source: APXvYqyNAzJyyIkRooVgrLqc96ZaB3g8apwlmlflB2vLTaGTiuWqG0Fdb/+vnuF9VAsjn+VaxwatzQ== X-Received: by 2002:a17:90a:8a0e:: with SMTP id w14mr13899092pjn.51.1576814084983; Thu, 19 Dec 2019 19:54:44 -0800 (PST) Received: from mannams-OptiPlex-7010.dhcp.broadcom.net ([192.19.234.250]) by smtp.gmail.com with ESMTPSA id t65sm10522205pfd.178.2019.12.19.19.54.40 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 19 Dec 2019 19:54:44 -0800 (PST) From: Srinath Mannam To: Lorenzo Pieralisi , Bjorn Helgaas , Florian Fainelli , Ray Jui , Rob Herring , Mark Rutland , Andy Shevchenko , Andrew Murray , Arnd Bergmann Cc: bcm-kernel-feedback-list@broadcom.com, linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Ray Jui , Srinath Mannam Subject: [PATCH v4 2/6] PCI: iproc: Add INTx support with better modeling Date: Fri, 20 Dec 2019 09:24:14 +0530 Message-Id: <1576814058-30003-3-git-send-email-srinath.mannam@broadcom.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1576814058-30003-1-git-send-email-srinath.mannam@broadcom.com> References: <1576814058-30003-1-git-send-email-srinath.mannam@broadcom.com> Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org From: Ray Jui Add PCIe legacy interrupt INTx support to the iProc PCIe driver by modeling it with its own IRQ domain. All 4 interrupts INTA, INTB, INTC, INTD share the same interrupt line connected to the GIC in the system, while the status of each INTx can be obtained through the INTX CSR register Signed-off-by: Ray Jui Signed-off-by: Srinath Mannam Reviewed-by: Andrew Murray --- drivers/pci/controller/pcie-iproc.c | 108 +++++++++++++++++++++++++++++++++++- drivers/pci/controller/pcie-iproc.h | 6 ++ 2 files changed, 112 insertions(+), 2 deletions(-) diff --git a/drivers/pci/controller/pcie-iproc.c b/drivers/pci/controller/pcie-iproc.c index 0a468c7..485967b 100644 --- a/drivers/pci/controller/pcie-iproc.c +++ b/drivers/pci/controller/pcie-iproc.c @@ -14,6 +14,7 @@ #include #include #include +#include #include #include #include @@ -270,6 +271,7 @@ enum iproc_pcie_reg { /* enable INTx */ IPROC_PCIE_INTX_EN, + IPROC_PCIE_INTX_CSR, /* outbound address mapping */ IPROC_PCIE_OARR0, @@ -314,6 +316,7 @@ static const u16 iproc_pcie_reg_paxb_bcma[] = { [IPROC_PCIE_CFG_ADDR] = 0x1f8, [IPROC_PCIE_CFG_DATA] = 0x1fc, [IPROC_PCIE_INTX_EN] = 0x330, + [IPROC_PCIE_INTX_CSR] = 0x334, [IPROC_PCIE_LINK_STATUS] = 0xf0c, }; @@ -325,6 +328,7 @@ static const u16 iproc_pcie_reg_paxb[] = { [IPROC_PCIE_CFG_ADDR] = 0x1f8, [IPROC_PCIE_CFG_DATA] = 0x1fc, [IPROC_PCIE_INTX_EN] = 0x330, + [IPROC_PCIE_INTX_CSR] = 0x334, [IPROC_PCIE_OARR0] = 0xd20, [IPROC_PCIE_OMAP0] = 0xd40, [IPROC_PCIE_OARR1] = 0xd28, @@ -341,6 +345,7 @@ static const u16 iproc_pcie_reg_paxb_v2[] = { [IPROC_PCIE_CFG_ADDR] = 0x1f8, [IPROC_PCIE_CFG_DATA] = 0x1fc, [IPROC_PCIE_INTX_EN] = 0x330, + [IPROC_PCIE_INTX_CSR] = 0x334, [IPROC_PCIE_OARR0] = 0xd20, [IPROC_PCIE_OMAP0] = 0xd40, [IPROC_PCIE_OARR1] = 0xd28, @@ -846,9 +851,103 @@ static int iproc_pcie_check_link(struct iproc_pcie *pcie) return link_is_active ? 0 : -ENODEV; } -static void iproc_pcie_enable(struct iproc_pcie *pcie) +static int iproc_pcie_intx_map(struct irq_domain *domain, unsigned int irq, + irq_hw_number_t hwirq) { + irq_set_chip_and_handler(irq, &dummy_irq_chip, handle_simple_irq); + irq_set_chip_data(irq, domain->host_data); + + return 0; +} + +static const struct irq_domain_ops intx_domain_ops = { + .map = iproc_pcie_intx_map, +}; + +static void iproc_pcie_isr(struct irq_desc *desc) +{ + struct irq_chip *chip = irq_desc_get_chip(desc); + struct iproc_pcie *pcie; + struct device *dev; + unsigned long status; + u32 bit, virq; + + chained_irq_enter(chip, desc); + pcie = irq_desc_get_handler_data(desc); + dev = pcie->dev; + + /* go through INTx A, B, C, D until all interrupts are handled */ + do { + status = iproc_pcie_read_reg(pcie, IPROC_PCIE_INTX_CSR); + for_each_set_bit(bit, &status, PCI_NUM_INTX) { + virq = irq_find_mapping(pcie->irq_domain, bit); + if (virq) + generic_handle_irq(virq); + else + dev_err(dev, "unexpected INTx%u\n", bit); + } + } while ((status & SYS_RC_INTX_MASK) != 0); + + chained_irq_exit(chip, desc); +} + +static int iproc_pcie_intx_enable(struct iproc_pcie *pcie) +{ + struct device *dev = pcie->dev; + struct device_node *node; + int ret; + + /* + * BCMA devices do not map INTx the same way as platform devices. All + * BCMA needs below line to enable INTx + */ iproc_pcie_write_reg(pcie, IPROC_PCIE_INTX_EN, SYS_RC_INTX_MASK); + + node = of_get_compatible_child(dev->of_node, "brcm,iproc-intc"); + if (node) + pcie->irq = of_irq_get(node, 0); + + if (!node || pcie->irq <= 0) + return 0; + + /* set IRQ handler */ + irq_set_chained_handler_and_data(pcie->irq, iproc_pcie_isr, pcie); + + /* add IRQ domain for INTx */ + pcie->irq_domain = irq_domain_add_linear(node, PCI_NUM_INTX, + &intx_domain_ops, pcie); + if (!pcie->irq_domain) { + dev_err(dev, "failed to add INTx IRQ domain\n"); + ret = -ENOMEM; + goto err_rm_handler_data; + } + + return 0; + +err_rm_handler_data: + of_node_put(node); + irq_set_chained_handler_and_data(pcie->irq, NULL, NULL); + + return ret; +} + +static void iproc_pcie_intx_disable(struct iproc_pcie *pcie) +{ + uint32_t offset, virq; + + iproc_pcie_write_reg(pcie, IPROC_PCIE_INTX_EN, 0x0); + + if (pcie->irq <= 0) + return; + + for (offset = 0; offset < PCI_NUM_INTX; offset++) { + virq = irq_find_mapping(pcie->irq_domain, offset); + if (virq) + irq_dispose_mapping(virq); + } + + irq_domain_remove(pcie->irq_domain); + irq_set_chained_handler_and_data(pcie->irq, NULL, NULL); } static inline bool iproc_pcie_ob_is_valid(struct iproc_pcie *pcie, @@ -1518,7 +1617,11 @@ int iproc_pcie_setup(struct iproc_pcie *pcie, struct list_head *res) goto err_power_off_phy; } - iproc_pcie_enable(pcie); + ret = iproc_pcie_intx_enable(pcie); + if (ret) { + dev_err(dev, "failed to enable INTx\n"); + goto err_power_off_phy; + } if (IS_ENABLED(CONFIG_PCI_MSI)) if (iproc_pcie_msi_enable(pcie)) @@ -1562,6 +1665,7 @@ int iproc_pcie_remove(struct iproc_pcie *pcie) pci_remove_root_bus(pcie->root_bus); iproc_pcie_msi_disable(pcie); + iproc_pcie_intx_disable(pcie); phy_power_off(pcie->phy); phy_exit(pcie->phy); diff --git a/drivers/pci/controller/pcie-iproc.h b/drivers/pci/controller/pcie-iproc.h index 4f03ea5..103e568 100644 --- a/drivers/pci/controller/pcie-iproc.h +++ b/drivers/pci/controller/pcie-iproc.h @@ -74,6 +74,9 @@ struct iproc_msi; * @ib: inbound mapping related parameters * @ib_map: outbound mapping region related parameters * + * @irq: interrupt line wired to the generic GIC for INTx + * @irq_domain: IRQ domain for INTx + * * @need_msi_steer: indicates additional configuration of the iProc PCIe * controller is required to steer MSI writes to external interrupt controller * @msi: MSI data @@ -102,6 +105,9 @@ struct iproc_pcie { struct iproc_pcie_ib ib; const struct iproc_pcie_ib_map *ib_map; + int irq; + struct irq_domain *irq_domain; + bool need_msi_steer; struct iproc_msi *msi; }; From patchwork Fri Dec 20 03:54:15 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinath Mannam X-Patchwork-Id: 11304749 X-Patchwork-Delegate: lorenzo.pieralisi@arm.com Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 2460A921 for ; Fri, 20 Dec 2019 03:54:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 0268824682 for ; Fri, 20 Dec 2019 03:54:55 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b="XbH99UFd" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727269AbfLTDyv (ORCPT ); Thu, 19 Dec 2019 22:54:51 -0500 Received: from mail-pf1-f195.google.com ([209.85.210.195]:32804 "EHLO mail-pf1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727190AbfLTDyu (ORCPT ); Thu, 19 Dec 2019 22:54:50 -0500 Received: by mail-pf1-f195.google.com with SMTP id z16so4475841pfk.0 for ; Thu, 19 Dec 2019 19:54:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=csAZpz1aDlZN19GUotv3truaMbqTwx/sneZlPvFv09g=; b=XbH99UFd3Yc1WQYJdi3wfqgj7LA4xRGdaTXRVXgL+J+eQfkRnZOH8RE8WCvi5LTkGT VRVarm3JHCBeCR2uu2HGov1iKPNd/d1dEpU2uYF163DC30qGO/hhsqb4Go97srZ1k62K OCQH72UlQmvGcUCmX7SQWIQ50aNkz0mi4qbyY= 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; bh=csAZpz1aDlZN19GUotv3truaMbqTwx/sneZlPvFv09g=; b=HrQC3mwguLHKv1s96JHwcUB4UqS1xn3jJqnEXAH10CiDYUdrxY1r4kHxHM8PkY3QQu WgkVTJxQxPOR9YgOUUnDXYWomzlAVLC+WDIv5z98sC0+V3KohjwUWFw6tPhUMlUqpyST S3aunWJMAF59XP5n+SLkjDCyJTEIARaPFgmfem5I4VkUYB4P9z38FjXbPaS3oR+7Bpd4 y0pGuRrlko7ABvujL3tQEH9ZZp+N5CvBaaRQkMyLHqICVi20w2t+oZEj3igC9Ndz2Xje wquMbhBOP8baEoiSLm0pSkzXhHM+lcSMvmYojO6h+d1PNVHnLFDD5rju1cRgQL644sMm V+mQ== X-Gm-Message-State: APjAAAUHC9Q4Q1I+Jw+PD5Jy+a4jeq2fLg1/GWWtfAhSR8b9hk4ku318 yvBNS49yJY4+YyMe4ssFHfuueQ== X-Google-Smtp-Source: APXvYqxAPNCcAHqjrFYqAfO36aS4XBHic4sg/Y9dBgXZhEioOz1V1hEFGKEqm4nd8e3aViOZso17ZA== X-Received: by 2002:a62:788a:: with SMTP id t132mr13743427pfc.134.1576814090019; Thu, 19 Dec 2019 19:54:50 -0800 (PST) Received: from mannams-OptiPlex-7010.dhcp.broadcom.net ([192.19.234.250]) by smtp.gmail.com with ESMTPSA id t65sm10522205pfd.178.2019.12.19.19.54.45 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 19 Dec 2019 19:54:49 -0800 (PST) From: Srinath Mannam To: Lorenzo Pieralisi , Bjorn Helgaas , Florian Fainelli , Ray Jui , Rob Herring , Mark Rutland , Andy Shevchenko , Andrew Murray , Arnd Bergmann Cc: bcm-kernel-feedback-list@broadcom.com, linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Ray Jui , Srinath Mannam Subject: [PATCH v4 3/6] arm: dts: Change PCIe INTx mapping for Cygnus Date: Fri, 20 Dec 2019 09:24:15 +0530 Message-Id: <1576814058-30003-4-git-send-email-srinath.mannam@broadcom.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1576814058-30003-1-git-send-email-srinath.mannam@broadcom.com> References: <1576814058-30003-1-git-send-email-srinath.mannam@broadcom.com> Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org From: Ray Jui Change the PCIe INTx mapping to model the 4 INTx interrupts in the IRQ domain of the iProc PCIe controller itself Signed-off-by: Ray Jui Signed-off-by: Srinath Mannam --- arch/arm/boot/dts/bcm-cygnus.dtsi | 30 ++++++++++++++++++++++++++---- 1 file changed, 26 insertions(+), 4 deletions(-) diff --git a/arch/arm/boot/dts/bcm-cygnus.dtsi b/arch/arm/boot/dts/bcm-cygnus.dtsi index 2dac3ef..ca23e82 100644 --- a/arch/arm/boot/dts/bcm-cygnus.dtsi +++ b/arch/arm/boot/dts/bcm-cygnus.dtsi @@ -264,8 +264,11 @@ reg = <0x18012000 0x1000>; #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0>; - interrupt-map = <0 0 0 0 &gic GIC_SPI 100 IRQ_TYPE_LEVEL_HIGH>; + interrupt-map-mask = <0 0 0 7>; + interrupt-map = <0 0 0 1 &pcie0_intc 0>, + <0 0 0 2 &pcie0_intc 1>, + <0 0 0 3 &pcie0_intc 2>, + <0 0 0 4 &pcie0_intc 3>; linux,pci-domain = <0>; @@ -292,6 +295,14 @@ , ; }; + + pcie0_intc: interrupt-controller { + compatible = "brcm,iproc-intc"; + interrupt-controller; + #interrupt-cells = <1>; + interrupt-parent = <&gic>; + interrupts = ; + }; }; pcie1: pcie@18013000 { @@ -299,8 +310,11 @@ reg = <0x18013000 0x1000>; #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0>; - interrupt-map = <0 0 0 0 &gic GIC_SPI 106 IRQ_TYPE_LEVEL_HIGH>; + interrupt-map-mask = <0 0 0 7>; + interrupt-map = <0 0 0 1 &pcie1_intc 0>, + <0 0 0 2 &pcie1_intc 1>, + <0 0 0 3 &pcie1_intc 2>, + <0 0 0 4 &pcie1_intc 3>; linux,pci-domain = <1>; @@ -327,6 +341,14 @@ , ; }; + + pcie1_intc: interrupt-controller { + compatible = "brcm,iproc-intc"; + interrupt-controller; + #interrupt-cells = <1>; + interrupt-parent = <&gic>; + interrupts = ; + }; }; dma0: dma@18018000 { From patchwork Fri Dec 20 03:54:16 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinath Mannam X-Patchwork-Id: 11304751 X-Patchwork-Delegate: lorenzo.pieralisi@arm.com Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 4809C13A4 for ; Fri, 20 Dec 2019 03:54:57 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 26CD324682 for ; Fri, 20 Dec 2019 03:54:57 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b="NLVU8mmM" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727258AbfLTDy4 (ORCPT ); Thu, 19 Dec 2019 22:54:56 -0500 Received: from mail-pf1-f193.google.com ([209.85.210.193]:36682 "EHLO mail-pf1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727291AbfLTDy4 (ORCPT ); Thu, 19 Dec 2019 22:54:56 -0500 Received: by mail-pf1-f193.google.com with SMTP id x184so4471523pfb.3 for ; Thu, 19 Dec 2019 19:54:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=HjO9w3K+DhLv6DGPP4CnPl74iRTy3HmYOjIjOtLnJCY=; b=NLVU8mmMh0OuZFo5FioB+xL49a7TXbGb0l0JnlM0+44ShP/xZdIwLQJROJbINm/JHX lZHzpUgMh6JPoUHS98DWiguUctdzmFIv0PQwccHe/I8qeAqQQQq7gyB2tHNkC0gNXtM8 RC1p+dyU6TbsP3cVgnxT6m5ewlPOr4SzS/3wk= 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; bh=HjO9w3K+DhLv6DGPP4CnPl74iRTy3HmYOjIjOtLnJCY=; b=mPkbIKAakzTU9cdYm6VD6yFSsvSaCHl4obyfX0ac+oQmsl7pGeVf3JT//wC5djyoQ8 IlUqyqG6omAeYyKbw/SGt2o9Sn5aA4VO7jACJAdQZupju/VkGwTvwqm6mpmS4ooGOQxq m3YihzcSZ8GiSuo8puZd3pZdowIgpstTFiLmjp6LkKzqVG0YT99qiXGRskf+S0eviQML NZWforq3qbnG86ZXHOa5VS0DhPGdwkv6x94IZ4nMqTFB2T3jNnmQ4tIZP9ct2jajQBQA bDIusQI/sncZeqxCcSB68KiPjiHVrmBVkN8JEF72zdhgisnwjMjJKyEurv9ChvBAKhUe bbvw== X-Gm-Message-State: APjAAAVon65/Ov0MvF9BoOqjsdLe/nALhtWdyvfS9BvogndHMvz+0HPD 5HC7nlvqCIVD7MUQMb97kUkhyw== X-Google-Smtp-Source: APXvYqzuOoyic8K2nHA/j78B4PNAtlCcRmLYgMDR9oD0rHduorOa5hz7OMRLWUc/enOsuSJhIO5Rzg== X-Received: by 2002:a62:8602:: with SMTP id x2mr13760012pfd.39.1576814095155; Thu, 19 Dec 2019 19:54:55 -0800 (PST) Received: from mannams-OptiPlex-7010.dhcp.broadcom.net ([192.19.234.250]) by smtp.gmail.com with ESMTPSA id t65sm10522205pfd.178.2019.12.19.19.54.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 19 Dec 2019 19:54:54 -0800 (PST) From: Srinath Mannam To: Lorenzo Pieralisi , Bjorn Helgaas , Florian Fainelli , Ray Jui , Rob Herring , Mark Rutland , Andy Shevchenko , Andrew Murray , Arnd Bergmann Cc: bcm-kernel-feedback-list@broadcom.com, linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Ray Jui , Srinath Mannam Subject: [PATCH v4 4/6] arm: dts: Change PCIe INTx mapping for NSP Date: Fri, 20 Dec 2019 09:24:16 +0530 Message-Id: <1576814058-30003-5-git-send-email-srinath.mannam@broadcom.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1576814058-30003-1-git-send-email-srinath.mannam@broadcom.com> References: <1576814058-30003-1-git-send-email-srinath.mannam@broadcom.com> Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org From: Ray Jui Change the PCIe INTx mapping to model the 4 INTx interrupts in the IRQ domain of the iProc PCIe controller itself Signed-off-by: Ray Jui Signed-off-by: Srinath Mannam --- arch/arm/boot/dts/bcm-nsp.dtsi | 45 ++++++++++++++++++++++++++++++++++++------ 1 file changed, 39 insertions(+), 6 deletions(-) diff --git a/arch/arm/boot/dts/bcm-nsp.dtsi b/arch/arm/boot/dts/bcm-nsp.dtsi index da6d70f..6d73221 100644 --- a/arch/arm/boot/dts/bcm-nsp.dtsi +++ b/arch/arm/boot/dts/bcm-nsp.dtsi @@ -529,8 +529,11 @@ reg = <0x18012000 0x1000>; #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0>; - interrupt-map = <0 0 0 0 &gic GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>; + interrupt-map-mask = <0 0 0 7>; + interrupt-map = <0 0 0 1 &pcie0_intc 0>, + <0 0 0 2 &pcie0_intc 1>, + <0 0 0 3 &pcie0_intc 2>, + <0 0 0 4 &pcie0_intc 3>; linux,pci-domain = <0>; @@ -559,6 +562,14 @@ ; brcm,pcie-msi-inten; }; + + pcie0_intc: interrupt-controller { + compatible = "brcm,iproc-intc"; + interrupt-controller; + #interrupt-cells = <1>; + interrupt-parent = <&gic>; + interrupts = ; + }; }; pcie1: pcie@18013000 { @@ -566,8 +577,11 @@ reg = <0x18013000 0x1000>; #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0>; - interrupt-map = <0 0 0 0 &gic GIC_SPI 137 IRQ_TYPE_LEVEL_HIGH>; + interrupt-map-mask = <0 0 0 7>; + interrupt-map = <0 0 0 1 &pcie1_intc 0>, + <0 0 0 2 &pcie1_intc 1>, + <0 0 0 3 &pcie1_intc 2>, + <0 0 0 4 &pcie1_intc 3>; linux,pci-domain = <1>; @@ -596,6 +610,14 @@ ; brcm,pcie-msi-inten; }; + + pcie1_intc: interrupt-controller { + compatible = "brcm,iproc-intc"; + interrupt-controller; + #interrupt-cells = <1>; + interrupt-parent = <&gic>; + interrupts = ; + }; }; pcie2: pcie@18014000 { @@ -603,8 +625,11 @@ reg = <0x18014000 0x1000>; #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0>; - interrupt-map = <0 0 0 0 &gic GIC_SPI 143 IRQ_TYPE_LEVEL_HIGH>; + interrupt-map-mask = <0 0 0 7>; + interrupt-map = <0 0 0 1 &pcie2_intc 0>, + <0 0 0 2 &pcie2_intc 1>, + <0 0 0 3 &pcie2_intc 2>, + <0 0 0 4 &pcie2_intc 3>; linux,pci-domain = <2>; @@ -633,6 +658,14 @@ ; brcm,pcie-msi-inten; }; + + pcie2_intc: interrupt-controller { + compatible = "brcm,iproc-intc"; + interrupt-controller; + #interrupt-cells = <1>; + interrupt-parent = <&gic>; + interrupts = ; + }; }; thermal-zones { From patchwork Fri Dec 20 03:54:17 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinath Mannam X-Patchwork-Id: 11304755 X-Patchwork-Delegate: lorenzo.pieralisi@arm.com Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 0FFBF921 for ; Fri, 20 Dec 2019 03:55:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id E1EB22468D for ; Fri, 20 Dec 2019 03:55:01 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b="aUmizb0+" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727345AbfLTDzB (ORCPT ); Thu, 19 Dec 2019 22:55:01 -0500 Received: from mail-pf1-f196.google.com ([209.85.210.196]:41445 "EHLO mail-pf1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727298AbfLTDzA (ORCPT ); Thu, 19 Dec 2019 22:55:00 -0500 Received: by mail-pf1-f196.google.com with SMTP id w62so4455534pfw.8 for ; Thu, 19 Dec 2019 19:55:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=80PtSg1u55ZhNt7+LPSiTJ6+bt+JAt6rBXPSWmOI82I=; b=aUmizb0+zD2VcF7lVovq9TPL4D8F6LNSEt6ce6NUu7ySDS0BLO+D5uvb/boR8VojnY MNPbpURDE6dxA6eo7U7qmqaS8GsEJH7igohDdsMyh0cb/uWsWX5kFlaovnOf39aSRVDt n85lQ6jfnibKHAzN8tlhk23kON8Qm1kDhKQlA= 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; bh=80PtSg1u55ZhNt7+LPSiTJ6+bt+JAt6rBXPSWmOI82I=; b=ZnlHiYjsl3wGOLYdtMy1ZZDl5WW5tvrWMd2h8nHpiV38G/HZvhjxcXmXBE1F18IRtT 1GF4BbnYYDkw/BqGXREmwt5GgCuxwPgoFkGrp4U019d78p0JLxvNtenVwErGeL4dwINf nPB4Qn5/iqYTxVUipdPiuUpCz24BlNnUx+lnBk8oXaaHlJH0u+Ck/hH51VFGrtWkZqgw Hgp0iA2gaRm3i1OSTvXn5ZlUpH0q59S+rXkS7BWP3cFmD3L1MBz1sLF/sNoeTCj4QE0f zPu3X05IGO1RG2OhF1S8B0euPjDPh9t/yntoAZqQEfSD38t6KhKtIB8ezOpgCHML1a+w Nt2Q== X-Gm-Message-State: APjAAAWB4nQuPurmIp6ndE7r/NCcb1xt4q5YoBIYE2c3xNPIZkxev/6s nswcP/OsPpQryKzCSFuLXM/3hw== X-Google-Smtp-Source: APXvYqxzHyYq4HR2GieaJsANZq1/5hn644qXmZ9mOkkCrPxU3HigyJ4QjjOEY1zrZWBhHYCfOWJewg== X-Received: by 2002:a63:4f59:: with SMTP id p25mr12536799pgl.230.1576814100194; Thu, 19 Dec 2019 19:55:00 -0800 (PST) Received: from mannams-OptiPlex-7010.dhcp.broadcom.net ([192.19.234.250]) by smtp.gmail.com with ESMTPSA id t65sm10522205pfd.178.2019.12.19.19.54.55 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 19 Dec 2019 19:54:59 -0800 (PST) From: Srinath Mannam To: Lorenzo Pieralisi , Bjorn Helgaas , Florian Fainelli , Ray Jui , Rob Herring , Mark Rutland , Andy Shevchenko , Andrew Murray , Arnd Bergmann Cc: bcm-kernel-feedback-list@broadcom.com, linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Ray Jui , Srinath Mannam Subject: [PATCH v4 5/6] arm: dts: Change PCIe INTx mapping for HR2 Date: Fri, 20 Dec 2019 09:24:17 +0530 Message-Id: <1576814058-30003-6-git-send-email-srinath.mannam@broadcom.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1576814058-30003-1-git-send-email-srinath.mannam@broadcom.com> References: <1576814058-30003-1-git-send-email-srinath.mannam@broadcom.com> Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org From: Ray Jui Change the PCIe INTx mapping to model the 4 INTx interrupts in the IRQ domain of the iProc PCIe controller itself Signed-off-by: Ray Jui Signed-off-by: Srinath Mannam --- arch/arm/boot/dts/bcm-hr2.dtsi | 30 ++++++++++++++++++++++++++---- 1 file changed, 26 insertions(+), 4 deletions(-) diff --git a/arch/arm/boot/dts/bcm-hr2.dtsi b/arch/arm/boot/dts/bcm-hr2.dtsi index 6142c67..80c3add 100644 --- a/arch/arm/boot/dts/bcm-hr2.dtsi +++ b/arch/arm/boot/dts/bcm-hr2.dtsi @@ -299,8 +299,11 @@ reg = <0x18012000 0x1000>; #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0>; - interrupt-map = <0 0 0 0 &gic GIC_SPI 186 IRQ_TYPE_LEVEL_HIGH>; + interrupt-map-mask = <0 0 0 7>; + interrupt-map = <0 0 0 1 &pcie0_intc 0>, + <0 0 0 2 &pcie0_intc 1>, + <0 0 0 3 &pcie0_intc 2>, + <0 0 0 4 &pcie0_intc 3>; linux,pci-domain = <0>; @@ -328,6 +331,14 @@ ; brcm,pcie-msi-inten; }; + + pcie0_intc: interrupt-controller { + compatible = "brcm,iproc-intc"; + interrupt-controller; + #interrupt-cells = <1>; + interrupt-parent = <&gic>; + interrupts = ; + }; }; pcie1: pcie@18013000 { @@ -335,8 +346,11 @@ reg = <0x18013000 0x1000>; #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0>; - interrupt-map = <0 0 0 0 &gic GIC_SPI 192 IRQ_TYPE_LEVEL_HIGH>; + interrupt-map-mask = <0 0 0 7>; + interrupt-map = <0 0 0 1 &pcie1_intc 0>, + <0 0 0 2 &pcie1_intc 1>, + <0 0 0 3 &pcie1_intc 2>, + <0 0 0 4 &pcie1_intc 3>; linux,pci-domain = <1>; @@ -364,5 +378,13 @@ ; brcm,pcie-msi-inten; }; + + pcie1_intc: interrupt-controller { + compatible = "brcm,iproc-intc"; + interrupt-controller; + #interrupt-cells = <1>; + interrupt-parent = <&gic>; + interrupts = ; + }; }; }; From patchwork Fri Dec 20 03:54:18 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinath Mannam X-Patchwork-Id: 11304757 X-Patchwork-Delegate: lorenzo.pieralisi@arm.com Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 3EFA2921 for ; Fri, 20 Dec 2019 03:55:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 1D5D32468C for ; Fri, 20 Dec 2019 03:55:07 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b="Ugw/aAKc" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727390AbfLTDzG (ORCPT ); Thu, 19 Dec 2019 22:55:06 -0500 Received: from mail-pl1-f194.google.com ([209.85.214.194]:36331 "EHLO mail-pl1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727344AbfLTDzG (ORCPT ); Thu, 19 Dec 2019 22:55:06 -0500 Received: by mail-pl1-f194.google.com with SMTP id a6so2776333plm.3 for ; Thu, 19 Dec 2019 19:55:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=ovwMqTunBsTOC/CqSHDUi6kBW0F5coIGszg1T7U+mmc=; b=Ugw/aAKctEDVCy2E9Jnvv9tHDoIpDDehFz+T8+8aZI9cywj2KBlcwfzfh7mdCYik2O 6IN4WKFXJzHgEZIa2XxRDQevv8ZJskvQehHtPy9eq3eJlXbnv3s6NMVIoQgcemtvFC0g OpT1biszj6pl06q1BV41iz/vpa/x0wDxPxovw= 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; bh=ovwMqTunBsTOC/CqSHDUi6kBW0F5coIGszg1T7U+mmc=; b=nTHrUQ62LjAQUF6H/TwbumWAGg7GQv5bufsT3zc5cRX05Dlwsdf7GDvK5TWwX/xvop pB+UHSpnpqOp3WtQU/j/AZKbEpYFKlQ5SwNpwHR5Lvaw3FHWuY+yLF3f+qXYKcjyEiVZ 2UaOcZpWYths0M78a5yV42lRIqBfnfxReyUFyonxSm56iKY998KUbPOlSGRN+2zMA7oV SBUC0B+P7y+dClG9FNDxDS5HoZXLJphQi+78o1hhH2P3DZo5LIMUfrCiz3N4/s43516w nQpIwyO4ROPY38w/CI9dyXv1pmifQTh3B/Cu8kXXZPfdTgiBvmWYDvHxu7LyKQeKP+XH 7Wug== X-Gm-Message-State: APjAAAV1vBKLtOawDNaaEAzeQzS8Vdt0eiC2tJO/6X820T5RVNdjuHKW 3gQdr3kcXDaxDp2Y01oCNq4j1w== X-Google-Smtp-Source: APXvYqySAxX6cI6Csq/zjMK84YWQHTPp16rdaC7UvgT0ndq3+F8fteQB9Vwa78q2KJtTGR3xyfygWw== X-Received: by 2002:a17:90a:bf0c:: with SMTP id c12mr13085792pjs.112.1576814105379; Thu, 19 Dec 2019 19:55:05 -0800 (PST) Received: from mannams-OptiPlex-7010.dhcp.broadcom.net ([192.19.234.250]) by smtp.gmail.com with ESMTPSA id t65sm10522205pfd.178.2019.12.19.19.55.00 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 19 Dec 2019 19:55:04 -0800 (PST) From: Srinath Mannam To: Lorenzo Pieralisi , Bjorn Helgaas , Florian Fainelli , Ray Jui , Rob Herring , Mark Rutland , Andy Shevchenko , Andrew Murray , Arnd Bergmann Cc: bcm-kernel-feedback-list@broadcom.com, linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Ray Jui , Srinath Mannam Subject: [PATCH v4 6/6] arm64: dts: Change PCIe INTx mapping for NS2 Date: Fri, 20 Dec 2019 09:24:18 +0530 Message-Id: <1576814058-30003-7-git-send-email-srinath.mannam@broadcom.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1576814058-30003-1-git-send-email-srinath.mannam@broadcom.com> References: <1576814058-30003-1-git-send-email-srinath.mannam@broadcom.com> Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org From: Ray Jui Change the PCIe INTx mapping to model the 4 INTx interrupts in the IRQ domain of the iProc PCIe controller itself Signed-off-by: Ray Jui Signed-off-by: Srinath Mannam --- arch/arm64/boot/dts/broadcom/northstar2/ns2.dtsi | 28 ++++++++++++++++++++---- 1 file changed, 24 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/broadcom/northstar2/ns2.dtsi b/arch/arm64/boot/dts/broadcom/northstar2/ns2.dtsi index 15f7b0e..489bfd5 100644 --- a/arch/arm64/boot/dts/broadcom/northstar2/ns2.dtsi +++ b/arch/arm64/boot/dts/broadcom/northstar2/ns2.dtsi @@ -117,8 +117,11 @@ dma-coherent; #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0>; - interrupt-map = <0 0 0 0 &gic 0 GIC_SPI 281 IRQ_TYPE_LEVEL_HIGH>; + interrupt-map-mask = <0 0 0 7>; + interrupt-map = <0 0 0 1 &pcie0_intc 0>, + <0 0 0 2 &pcie0_intc 1>, + <0 0 0 3 &pcie0_intc 2>, + <0 0 0 4 &pcie0_intc 3>; linux,pci-domain = <0>; @@ -140,6 +143,13 @@ phy-names = "pcie-phy"; msi-parent = <&v2m0>; + pcie0_intc: interrupt-controller { + compatible = "brcm,iproc-intc"; + interrupt-controller; + #interrupt-cells = <1>; + interrupt-parent = <&gic>; + interrupts = ; + }; }; pcie4: pcie@50020000 { @@ -148,8 +158,11 @@ dma-coherent; #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0>; - interrupt-map = <0 0 0 0 &gic 0 GIC_SPI 305 IRQ_TYPE_LEVEL_HIGH>; + interrupt-map-mask = <0 0 0 7>; + interrupt-map = <0 0 0 1 &pcie4_intc 0>, + <0 0 0 2 &pcie4_intc 1>, + <0 0 0 3 &pcie4_intc 2>, + <0 0 0 4 &pcie4_intc 3>; linux,pci-domain = <4>; @@ -171,6 +184,13 @@ phy-names = "pcie-phy"; msi-parent = <&v2m0>; + pcie4_intc: interrupt-controller { + compatible = "brcm,iproc-intc"; + interrupt-controller; + #interrupt-cells = <1>; + interrupt-parent = <&gic>; + interrupts = ; + }; }; pcie8: pcie@60c00000 {