From patchwork Thu Oct 10 14:57:06 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 20942 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pa0-f69.google.com (mail-pa0-f69.google.com [209.85.220.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id DA6342611D for ; Thu, 10 Oct 2013 14:57:15 +0000 (UTC) Received: by mail-pa0-f69.google.com with SMTP id kq14sf5070943pab.4 for ; Thu, 10 Oct 2013 07:57:14 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=mime-version:x-gm-message-state:delivered-to:from:to:cc:subject :date:message-id:x-original-sender:x-original-authentication-results :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-unsubscribe; bh=K+ukUQyy9Be54S4cbfbWmfQVG1ZRByh8OKzptZjISDo=; b=KGv42JCCwy7f24bf3y4KbPUw7cn3o+mGSN64CIcr7MdN5MOBgW6pvH5knqo+gFDNLp I6WrkvlVe9h0AqsBh8N2EU4yd23d4OyV7Qqo2fBbKv1DI+115t1Zw1XIk9JpJJj3hZpD MnfWcgitTCfii0189eC7fJahndHExQ5wDoGIxkp5taou39T5Slq3L42TJrMK8470Jq3k 8HpVWQdLGUvuaPP9Vu2caVLdOZX1UsnHu98wFHOYNG/C8pyHLIorwRgYI30aJIkPoYjS 0REJ8HEyQfxv0nGUeCoIq65D5DW5AckCZPBUCOtf71srsqS/i7VJ1exzUU/eyj8fBK9X G2sw== X-Received: by 10.66.186.4 with SMTP id fg4mr4845513pac.33.1381417034899; Thu, 10 Oct 2013 07:57:14 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.29.129 with SMTP id k1ls961026qeh.75.gmail; Thu, 10 Oct 2013 07:57:14 -0700 (PDT) X-Received: by 10.52.240.198 with SMTP id wc6mr6623059vdc.54.1381417034730; Thu, 10 Oct 2013 07:57:14 -0700 (PDT) Received: from mail-vb0-f54.google.com (mail-vb0-f54.google.com [209.85.212.54]) by mx.google.com with ESMTPS id de6si14394242vcb.109.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 10 Oct 2013 07:57:14 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.212.54 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.212.54; Received: by mail-vb0-f54.google.com with SMTP id q14so1684458vbe.41 for ; Thu, 10 Oct 2013 07:57:14 -0700 (PDT) X-Gm-Message-State: ALoCoQnPPK6AbhABr8NlSeN3ulT6RW66jrIEo4Gu6MEuD834u72fz5yccT1A9IzjAnks+uWmhK7W X-Received: by 10.52.37.69 with SMTP id w5mr8533749vdj.32.1381417034554; Thu, 10 Oct 2013 07:57:14 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp382395vcz; Thu, 10 Oct 2013 07:57:13 -0700 (PDT) X-Received: by 10.194.202.195 with SMTP id kk3mr2957188wjc.49.1381417033450; Thu, 10 Oct 2013 07:57:13 -0700 (PDT) Received: from mail-wi0-f179.google.com (mail-wi0-f179.google.com [209.85.212.179]) by mx.google.com with ESMTPS id g16si6278733wiv.79.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 10 Oct 2013 07:57:13 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.212.179 is neither permitted nor denied by best guess record for domain of linus.walleij@linaro.org) client-ip=209.85.212.179; Received: by mail-wi0-f179.google.com with SMTP id hm2so2744451wib.12 for ; Thu, 10 Oct 2013 07:57:12 -0700 (PDT) X-Received: by 10.194.222.2 with SMTP id qi2mr12792799wjc.14.1381417032680; Thu, 10 Oct 2013 07:57:12 -0700 (PDT) Received: from localhost.localdomain ([85.235.11.236]) by mx.google.com with ESMTPSA id s4sm2022520wiy.1.1969.12.31.16.00.00 (version=TLSv1.2 cipher=AES128-GCM-SHA256 bits=128/128); Thu, 10 Oct 2013 07:57:11 -0700 (PDT) From: Linus Walleij To: linux-arm-kernel@lists.infradead.org Cc: devicetree@vger.kernel.org, Mark Rutland , Linus Walleij Subject: [PATCH 1/6 v3] ARM: integrator: get the LM interrupts from DT Date: Thu, 10 Oct 2013 16:57:06 +0200 Message-Id: <1381417026-5791-1-git-send-email-linus.walleij@linaro.org> X-Mailer: git-send-email 1.8.3.1 X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: linus.walleij@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.212.54 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , The OF/DT boot path needs to get the LM (Logical Module) IRQs from the device tree for coherency. This augments the DT syscon node to contain these IRQs and alter the DT LM code to get them from there. Signed-off-by: Linus Walleij --- ChangeLog v2->v3: - Add some essential commas in the list. Mea culpa. ChangeLog v1->v2: - Updated documentation in accordance with Mark Ruthlands review comments. --- Documentation/devicetree/bindings/arm/arm-boards | 21 +++++++++++++++++++++ arch/arm/boot/dts/integratorap.dts | 3 +++ arch/arm/mach-integrator/integrator_ap.c | 2 +- 3 files changed, 25 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/arm/arm-boards b/Documentation/devicetree/bindings/arm/arm-boards index db5858e..5fdd7b9 100644 --- a/Documentation/devicetree/bindings/arm/arm-boards +++ b/Documentation/devicetree/bindings/arm/arm-boards @@ -9,9 +9,30 @@ Required properties (in root node): FPGA type interrupt controllers, see the versatile-fpga-irq binding doc. +Required nodes: + In the root node the Integrator/CP must have a /cpcon node pointing to the CP control registers, and the Integrator/AP must have a /syscon node pointing to the Integrator/AP system controller. +The AP syscon node must include the logic module interrupts, stated +in order of module instance +example: + +/dts-v1/; +/include/ "integrator.dtsi" + +/ { + model = "ARM Integrator/AP"; + compatible = "arm,integrator-ap"; + + syscon { + /* AP system controller registers */ + reg = <0x11000000 0x100>; + interrupt-parent = <&pic>; + /* These are the logic module IRQs */ + interrupts = <9>, <10>, <11>, <12>; + }; +}; ARM Versatile Application and Platform Baseboards diff --git a/arch/arm/boot/dts/integratorap.dts b/arch/arm/boot/dts/integratorap.dts index b6b82ec..453ab0e 100644 --- a/arch/arm/boot/dts/integratorap.dts +++ b/arch/arm/boot/dts/integratorap.dts @@ -21,6 +21,9 @@ syscon { /* AP system controller registers */ reg = <0x11000000 0x100>; + interrupt-parent = <&pic>; + /* These are the logical module IRQs */ + interrupts = <9>, <10>, <11>, <12>; }; timer0: timer@13000000 { diff --git a/arch/arm/mach-integrator/integrator_ap.c b/arch/arm/mach-integrator/integrator_ap.c index d9e95e6..f5fbd8a 100644 --- a/arch/arm/mach-integrator/integrator_ap.c +++ b/arch/arm/mach-integrator/integrator_ap.c @@ -541,7 +541,7 @@ static void __init ap_init_of(void) lmdev->resource.start = 0xc0000000 + 0x10000000 * i; lmdev->resource.end = lmdev->resource.start + 0x0fffffff; lmdev->resource.flags = IORESOURCE_MEM; - lmdev->irq = IRQ_AP_EXPINT0 + i; + lmdev->irq = irq_of_parse_and_map(syscon, i); lmdev->id = i; lm_device_register(lmdev);