From patchwork Thu May 25 08:18:52 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Guodong Xu X-Patchwork-Id: 100475 Delivered-To: patch@linaro.org Received: by 10.182.142.97 with SMTP id rv1csp731771obb; Thu, 25 May 2017 01:22:31 -0700 (PDT) X-Received: by 10.99.149.94 with SMTP id t30mr44630126pgn.152.1495700551183; Thu, 25 May 2017 01:22:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1495700551; cv=none; d=google.com; s=arc-20160816; b=TYTniwbjqFXYQ43CxyYdtlJsqRMZ0CIL+rWW6muTbKFI8NGP1xC7SKZVAGWdvGtUJU LnQznK7EgSPXbDvENAUrSXr3mxWedfTJH2B7cedxglYNuSMCpTPcRtI+6zajFHxtNQSl C/7FVzXb6T8A47pu3L5EMugI5Dgm9mfR5Qamr4M/FNzitbJujsr4aFK2r7kgvMzyqAe9 6RYT1PVLI3kPxMxJKbHZ6jfQT1DODPe1L4RA/Du0U3sqZTDf2vwJWxyPRIfY5J1Cebgy iETZc1r/fFrZ5OH3vaBqhWYxY8eb5OsEvlR7JVC1SEH3Woo4Yz8lHoW37W4oDQKJP+k8 76pg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=Tc7X27Au8ddnZ54jPJ/PqZqGXGoqfxSEw96S0/te/AU=; b=GXyTjxCCCW3tBgIeSaXf6z8840HDRwaCVDXlnXTna20V+ZnsqjPuo1iS4Bbj8DV+Ku layXXGhHQBYbjIsPP546XmeOD53tgu3uUWpZxGhj9VCXz9YoodR5UcTBzbR00BVCyWX4 MYqBtAyBwBflpH65gtAeEZGJdCSSqVHlPP42NSTIqAaD+sDWutV88uAPVCE8VgnBZSrJ 7RzIft7tsfAizpa454IkNErl4ULOd1JqKFKuzWoGHv8vyl0H7reF1a6a7Ha0wVEkQWY8 EB2JI5o3MwUGjdD7Sxmg/cB5+BBDwcncrF427pAJcntXZoXE7y7ZDColesy3/G3kZRu1 3ujQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u201si26788965pgb.404.2017.05.25.01.22.30; Thu, 25 May 2017 01:22:31 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S937575AbdEYIWV (ORCPT + 7 others); Thu, 25 May 2017 04:22:21 -0400 Received: from mail-pf0-f177.google.com ([209.85.192.177]:36497 "EHLO mail-pf0-f177.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1423675AbdEYIT6 (ORCPT ); Thu, 25 May 2017 04:19:58 -0400 Received: by mail-pf0-f177.google.com with SMTP id m17so160498949pfg.3 for ; Thu, 25 May 2017 01:19:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=X6/H86AoT9SYw5uZPqpjGBaeqytuolgQzVCEB6Bujm8=; b=b92Lwp6lRHcEC3hIVkMYZ+QdYRdiN5et963Kx9Ie/aCTfox4HrshbNeCEvjB+95jhR kfTp81unh6890oKFVlX9vD/B3gahTklAXVPrk0iFtAfIYoC9quwq3lZH3e/B1t4Bikkk WZ4dJiQuPaCQOtTwTkFzFL/MoI9620WcBB1DM= 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=X6/H86AoT9SYw5uZPqpjGBaeqytuolgQzVCEB6Bujm8=; b=KFX6cbNrUMpNtZhcD4CwnDLhve8t/26MtD5D+gdZ5IvCqKlvUTliniwOhFtzeuVh+7 CL1wKSD/MQSTkd4ypeTh1EE8sgQBbRHME/erZEPYIqGULD+/PZ9wJPvIh/G6smomYC/8 nfY3W4bgD34RISYULzXVXQsQIn1c5UWqituNwp+l5SP+TzdQZ9jU4Ru3XPSKv1PMbO7H pXmO1MtnsfS7iSL4LgnwK49TbuucJPA6mIY5XwjpqzX3udGmRrDOzWv61c1gpWsH1VUe ZEyP7sN6yLz4WyUEBx/SB/irygEOf7xXfFNaVNQIvldDG/lPchA7cV+7pFJ/fzvpaGgV VwjA== X-Gm-Message-State: AODbwcBrjoWMVfWHX5bMHF9ydgHU6WnEhPXwPZxXP6oFP52JxdMk596E EZPfC3g/EbNYIBeyo9Tnag== X-Received: by 10.84.225.130 with SMTP id u2mr47915658plj.91.1495700397967; Thu, 25 May 2017 01:19:57 -0700 (PDT) Received: from docularxu-ThinkPad-T440p.219.146.1.66 ([45.56.159.222]) by smtp.gmail.com with ESMTPSA id b72sm11574470pfd.118.2017.05.25.01.19.52 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 25 May 2017 01:19:57 -0700 (PDT) From: Guodong Xu To: robh+dt@kernel.org, mark.rutland@arm.com, xuwei5@hisilicon.com, catalin.marinas@arm.com, will.deacon@arm.com, wangkefeng.wang@huawei.com, xuejiancheng@hisilicon.com, peter.griffin@linaro.org, puck.chen@hisilicon.com Cc: zhangfei.gao@linaro.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Chen Jun , John Stultz , Guodong Xu Subject: [PATCH v2 10/12] arm64: dts: hi3660: add power key dts node Date: Thu, 25 May 2017 16:18:52 +0800 Message-Id: <20170525081854.4701-11-guodong.xu@linaro.org> X-Mailer: git-send-email 2.10.2 In-Reply-To: <20170525081854.4701-1-guodong.xu@linaro.org> References: <20170525081854.4701-1-guodong.xu@linaro.org> Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Chen Jun We use gpio_034 as power key on hikey960, and set gpio with pull-up state, when key press the voltage on the gpio will come to lower, and power key event will be reported. Signed-off-by: Chen Jun Signed-off-by: John Stultz Signed-off-by: Guodong Xu --- arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) -- 2.10.2 -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts b/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts index c25fff9..7aac35b 100644 --- a/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts +++ b/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts @@ -10,6 +10,8 @@ #include "hi3660.dtsi" #include "hikey960-pinctrl.dtsi" #include +#include +#include / { model = "HiKey960"; @@ -34,6 +36,19 @@ /* rewrite this at bootloader */ reg = <0x0 0x0 0x0 0x0>; }; + + keys { + compatible = "gpio-keys"; + pinctrl-names = "default"; + pinctrl-0 = <&pwr_key_pmx_func &pwr_key_cfg_func>; + + power { + wakeup-source; + gpios = <&gpio4 2 GPIO_ACTIVE_LOW>; + label = "GPIO Power"; + linux,code = ; + }; + }; }; &i2c0 {