From patchwork Tue Nov 20 06:53:11 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chen-Yu Tsai X-Patchwork-Id: 10690665 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 1066915A7 for ; Tue, 20 Nov 2018 16:07:45 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F337428535 for ; Tue, 20 Nov 2018 16:07:44 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E77B8285D6; Tue, 20 Nov 2018 16:07:44 +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=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id D877428535 for ; Tue, 20 Nov 2018 16:07:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=2tMXONdjIiS0FxnFdc+pPOs9z3VualmYCxrxP27kkYc=; b=afIjY8A0iA4rPn AFPHOecYeQ3NNRO75T7/bBOOdNNcU/qFEiTn2byz8LuZ4jzSuzpKD5s3VdWV3xJjdmosaL/2bSHqd IlAkciw5zfDBYjNFTY5/SGs80MWFNcsa0I15apDummm5AYcFyVH6qwf+NcO9vQ8QCUq7iQF57USQF AM3oAf58ZzzW2SO6gP7o1ozI9RMklm+ZQDNxeLbR3hwXFJln0ePhGS/wVkwvClNWo5C2maIILDHge d1cmUUSAWV3ZRHB06EUf8r909Z7lbWM1ndkiou56wjrQncb8UCsV5LrhIplw1wmv8Bopj+NVEZEL8 yEcgwbiJRgTWg2kZ4s/A==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gP8Yr-0005nu-CC; Tue, 20 Nov 2018 16:07:37 +0000 Received: from merlin.infradead.org ([205.233.59.134]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gP8HS-0003nl-Iz for linux-arm-kernel@bombadil.infradead.org; Tue, 20 Nov 2018 15:49:38 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=Content-Transfer-Encoding:MIME-Version: References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To: Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=EoPhPa5w+oLmVI2mThhb2BEuKJ1xIAtFIsJwus27i9s=; b=GkEdk3wRyiI5oCvx5j0cxUjxDU FUwfQAe8KDT9btdZR4i9HKrsMyEOxd71IJw3nBmYlXf2sCRLcwGdwz0Tqjvz1QClybBd4nKNj78P9 DjnmkbsZFIVfQUkssKmgwadq39DMQIk18Ko39U3VYV0e9hy8VHYRX5QANYLTb5gdnmMjKJBsHdW+5 /02699Nw6MKoLJeRcJhmjvTTy+axRP0jlkChP1AWmCMAenr8kW4pIcorP6mJVeCC7Dp327qd3YyNb 9vx/Or5TuaGHJ138iAO4faJtuSpjkOUVRYjJV10DimlyzznDILs4NsKfu5oKiHbwSVumfqOrVjf+l zbwYqk+g==; Received: from mirror2.csie.ntu.edu.tw ([140.112.30.76] helo=wens.csie.org) by merlin.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gOzuj-0004Ka-HP for linux-arm-kernel@lists.infradead.org; Tue, 20 Nov 2018 06:53:38 +0000 Received: by wens.csie.org (Postfix, from userid 1000) id 897445FCA9; Tue, 20 Nov 2018 14:53:16 +0800 (CST) From: Chen-Yu Tsai To: Maxime Ripard Subject: [PATCH 3/3] arm64: dts: allwinner: h6: orangepi: Add device nodes for LEDs Date: Tue, 20 Nov 2018 14:53:11 +0800 Message-Id: <20181120065311.30009-4-wens@csie.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181120065311.30009-1-wens@csie.org> References: <20181120065311.30009-1-wens@csie.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181120_015337_881353_B510344E X-CRM114-Status: GOOD ( 10.84 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Chen-Yu Tsai , linux-sunxi@googlegroups.com, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org 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 The Orange Pi Lite 2 and Orange Pi One Plus both have two LEDs, one red and one green. These are driven directly by GPIO lines in an active high arrangement. The red LED is labeled "power", so it is set to be on by default. Note that the default drive current for the GPIO lines makes the LEDs very bright. Signed-off-by: Chen-Yu Tsai --- .../boot/dts/allwinner/sun50i-h6-orangepi.dtsi | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi.dtsi index f16b7ffbe797..b2526dac2fcf 100644 --- a/arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi.dtsi +++ b/arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi.dtsi @@ -22,6 +22,21 @@ stdout-path = "serial0:115200n8"; }; + leds { + compatible = "gpio-leds"; + + power { + label = "orangepi:red:power"; + gpios = <&r_pio 0 4 GPIO_ACTIVE_HIGH>; /* PL4 */ + default-state = "on"; + }; + + status { + label = "orangepi:green:status"; + gpios = <&r_pio 0 7 GPIO_ACTIVE_HIGH>; /* PL7 */ + }; + }; + reg_vcc5v: vcc5v { /* board wide 5V supply directly from the DC jack */ compatible = "regulator-fixed";