From patchwork Fri May 29 02:14:07 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gregory Fong X-Patchwork-Id: 6504111 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 5F1589F38D for ; Fri, 29 May 2015 02:19:24 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 780152072B for ; Fri, 29 May 2015 02:19:23 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id AAA172070D for ; Fri, 29 May 2015 02:19:22 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1Yy9rH-0002gq-Iz; Fri, 29 May 2015 02:17:15 +0000 Received: from mail-pa0-x234.google.com ([2607:f8b0:400e:c03::234]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1Yy9pR-00008U-BD for linux-arm-kernel@lists.infradead.org; Fri, 29 May 2015 02:15:22 +0000 Received: by paza2 with SMTP id a2so37191894paz.3 for ; Thu, 28 May 2015 19:14:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=nqH67A7/rJ6XKCfw0jsyqlQNJ4K7PkSL13o50wvwPVA=; b=yuLbx/yYVfQ3d7+6W/uKRtMvjWAwGcmclwQZq6OkTP7fq8rLXYtQuBB2YQdbpMrQGF dIEhc7YKCqRA2DvEFz/vVEZb31SycDKkTj7JCW4sx/V6BNCA/WzaGtk++IGpf0tA5eHO YXZ6nswB/cblK9ZjcK/OWbUNQMrDXxRbu05G6265lqKSkm0mNYHlqLZPskBB3S5O+QfW ToO0W2XL6uqhthH2XN9ih791H8IJnXr96sDGR2Xnx4C8pRbSUKat8eoVFg/HfUyW7Vau czwy80rAIH/co63uqBBeRXt9n0O1xYCDqQAjmNTH6BTaEP8JgtzzwluXIH7UL0c94ZKw p6Xw== X-Received: by 10.68.88.33 with SMTP id bd1mr10908490pbb.124.1432865699734; Thu, 28 May 2015 19:14:59 -0700 (PDT) Received: from gregory-irv-00.irv.broadcom.com (5520-maca-inet1-outside.broadcom.com. [216.31.211.11]) by mx.google.com with ESMTPSA id ph4sm3722456pdb.43.2015.05.28.19.14.57 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 28 May 2015 19:14:58 -0700 (PDT) From: Gregory Fong To: linux-gpio@vger.kernel.org Subject: [PATCH v2 3/6] dt-bindings: brcmstb-gpio: document properties for wakeup Date: Thu, 28 May 2015 19:14:07 -0700 Message-Id: <1432865650-4062-4-git-send-email-gregory.0xf0@gmail.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1432865650-4062-1-git-send-email-gregory.0xf0@gmail.com> References: <1432865650-4062-1-git-send-email-gregory.0xf0@gmail.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150528_191521_473604_E220F7D6 X-CRM114-Status: GOOD ( 11.17 ) X-Spam-Score: -0.6 (/) Cc: Mark Rutland , Alexandre Courbot , Florian Fainelli , Russell King , Pawel Moll , devicetree@vger.kernel.org, Linus Walleij , Ian Campbell , linux-kernel@vger.kernel.org, Rob Herring , bcm-kernel-feedback-list@broadcom.com, Gregory Fong , Kumar Gala , Brian Norris , linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.1 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable 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 Some brcmstb GPIO controllers can be used to wake from suspend, so use the de facto standard property 'wakeup-source' to mark the nodes of controllers with that capability. Also document interrupts-extended, which will be used for wakeup handling because the interrupt parent for the wake IRQ is different from the regular IRQ. Signed-off-by: Gregory Fong Reviewed-by: Brian Norris --- New in v2. .../devicetree/bindings/gpio/brcm,brcmstb-gpio.txt | 26 +++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/gpio/brcm,brcmstb-gpio.txt b/Documentation/devicetree/bindings/gpio/brcm,brcmstb-gpio.txt index 435f1bc..568814f 100644 --- a/Documentation/devicetree/bindings/gpio/brcm,brcmstb-gpio.txt +++ b/Documentation/devicetree/bindings/gpio/brcm,brcmstb-gpio.txt @@ -33,6 +33,12 @@ Optional properties: - interrupt-parent: phandle of the parent interrupt controller +- interrupts-extended: + Alternate form of specifying interrupts and parents that allows for + multiple parents. This takes precedence over 'interrupts' and + 'interrupt-parent'. This probably must be used if the wakeup-source + property is provided because that may have a different interrupt parent. + - #interrupt-cells: Should be <2>. The first cell is the GPIO number, the second should specify flags. The following subset of flags is supported: @@ -48,7 +54,10 @@ Optional properties: Marks the device node as an interrupt controller - interrupt-names: - The name of the IRQ resource used by this controller + The names of the IRQ resources used by this controller + +- wakeup-source: + GPIOs for this controller can be used as a wakeup source Example: upg_gio: gpio@f040a700 { @@ -63,3 +72,18 @@ Example: interrupt-names = "upg_gio"; brcm,gpio-bank-widths = <0x20 0x20 0x20 0x18>; }; + + upg_gio_aon: gpio@f04172c0 { + #gpio-cells = <0x2>; + #interrupt-cells = <0x2>; + compatible = "brcm,bcm7445-gpio", "brcm,brcmstb-gpio"; + gpio-controller; + interrupt-controller; + reg = <0xf04172c0 0x40>; + interrupt-parent = <0xc>; + interrupts = <0x6>; + interrupts-extended = <0xc 0x6 0xa 0x5>; + interrupt-names = "upg_gio_aon", "upg_gio_aon_wakeup"; + wakeup-source; + brcm,gpio-bank-widths = <0x12 0x4>; + };