Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp3788510imm; Mon, 8 Oct 2018 09:30:44 -0700 (PDT) X-Google-Smtp-Source: ACcGV63iReQhcE4m047UO1bINVNjwBz8Qp7HNGiArPJrC9EO7yTitKdHRJBng+xP3zd6+q2RQhq3 X-Received: by 2002:a63:1752:: with SMTP id 18-v6mr22223876pgx.131.1539016243980; Mon, 08 Oct 2018 09:30:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1539016243; cv=none; d=google.com; s=arc-20160816; b=KQ0Sd2yW2JexgrLKdPNPxNUJZg4Qg5npVK6aD5N9F9c9N6jP3Ijc+g1Pa0stI/Q0YE 0L42GdFWMgz+iB3svimsa8VfN1kSZDXxc5Snt5ktSF6Eymrapsn3fgtpaXys6DR19HSQ n/cu8LAHL6ALo3vDgGKtLr4AvQK1gGDVJgG8vECTdRygna4Lxo85HgBWnniG02ZO68i2 vBjEw3pCaefAQGAHnVBZ+8Dy3MrtbJSnjGy5J0/ejwybVFu3cITFgtLd6/mWY+zGaCif OS9z0ESJ+8Am1U6D8RGPk5rqFNqJl/6Z9b8OscuKxbMvptWFKv5maCMlbwEvRyW0GyX5 zTNA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from; bh=jf0Sz2n6ck5c5gF1LjENO9wQ527lEydUq5pdvbkNVkk=; b=FKnJ4f/zgAt/U8WisgRUDu4X0Cmr6gEF/A6yLSZMyihDoMlosjy+6hu0RPrJQYtl7C 9SkZHRe9MphE8oGGvUHOzeSW6eUisx9H8xm6kc0Fc77A1LwL3dTGA3Q4W/5mbdb3hyyI tb0pDl/um7ZioEJF2fDOCLVKEJ7iZ4tRJoMJS0nuKks8D8OYb1dlNQFfckuM9ABcM4FH WnOHMlYspFnmPbeU6ieHyLd3HiTTk5V+5OrkKAtcqfVj+8kZKYCb8wiFau3eAoX/PmGV UFV9MKI5TKckKdSfgA8ZmDI5wBnac400Z8bSrWJKE38q7gMXPA6WLm8TlCF1iMaLqm5V PenQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 12-v6si14900373pgd.191.2018.10.08.09.30.27; Mon, 08 Oct 2018 09:30:43 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726713AbeJHXmi convert rfc822-to-8bit (ORCPT + 99 others); Mon, 8 Oct 2018 19:42:38 -0400 Received: from mx07-00178001.pphosted.com ([62.209.51.94]:2327 "EHLO mx07-00178001.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726418AbeJHXmi (ORCPT ); Mon, 8 Oct 2018 19:42:38 -0400 Received: from pps.filterd (m0046668.ppops.net [127.0.0.1]) by mx07-.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id w98GJhdH002950; Mon, 8 Oct 2018 18:29:42 +0200 Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx07-00178001.pphosted.com with ESMTP id 2mxjgxm25n-1 (version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT); Mon, 08 Oct 2018 18:29:42 +0200 Received: from zeta.dmz-eu.st.com (zeta.dmz-eu.st.com [164.129.230.9]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id CC3BE34; Mon, 8 Oct 2018 16:29:41 +0000 (GMT) Received: from Webmail-eu.st.com (sfhdag6node3.st.com [10.75.127.18]) by zeta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 9829557D1; Mon, 8 Oct 2018 16:29:41 +0000 (GMT) Received: from SFHDAG6NODE2.st.com (10.75.127.17) by SFHDAG6NODE3.st.com (10.75.127.18) with Microsoft SMTP Server (TLS) id 15.0.1347.2; Mon, 8 Oct 2018 18:29:41 +0200 Received: from SFHDAG6NODE2.st.com ([fe80::a56f:c186:bab7:13d6]) by SFHDAG6NODE2.st.com ([fe80::a56f:c186:bab7:13d6%20]) with mapi id 15.00.1347.000; Mon, 8 Oct 2018 18:29:41 +0200 From: Pascal PAILLET-LME To: "dmitry.torokhov@gmail.com" , "robh+dt@kernel.org" , "mark.rutland@arm.com" , "lee.jones@linaro.org" , "lgirdwood@gmail.com" , "broonie@kernel.org" , "wim@linux-watchdog.org" , "linux@roeck-us.net" , "linux-input@vger.kernel.org" , "devicetree@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-watchdog@vger.kernel.org" , "benjamin.gaignard@linaro.org" , "eballetbo@gmail.com" CC: Pascal PAILLET-LME Subject: [PATCH v3 5/8] dt-bindings: input: document stpmic1 pmic onkey Thread-Topic: [PATCH v3 5/8] dt-bindings: input: document stpmic1 pmic onkey Thread-Index: AQHUXyQdFh6gHFHM3kChRAEXRCfihA== Date: Mon, 8 Oct 2018 16:29:41 +0000 Message-ID: <1539016176-4072-6-git-send-email-p.paillet@st.com> References: <1539016176-4072-1-git-send-email-p.paillet@st.com> In-Reply-To: <1539016176-4072-1-git-send-email-p.paillet@st.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-messagesentrepresentingtype: 1 x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [10.75.127.49] Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2018-10-08_07:,, signatures=0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: pascal paillet The stpmic1 pmic is able to manage an onkey button. It can be configured to shut-down the power supplies on a long key-press with an adjustable duration. Signed-off-by: pascal paillet --- changes in v3: * Replace st,onkey-long-press-seconds and st,onkey-pwroff-enabled by power-off-time-sec. .../devicetree/bindings/input/st,stpmic1-onkey.txt | 30 ++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 Documentation/devicetree/bindings/input/st,stpmic1-onkey.txt diff --git a/Documentation/devicetree/bindings/input/st,stpmic1-onkey.txt b/Documentation/devicetree/bindings/input/st,stpmic1-onkey.txt new file mode 100644 index 0000000..8c58186 --- /dev/null +++ b/Documentation/devicetree/bindings/input/st,stpmic1-onkey.txt @@ -0,0 +1,30 @@ +STMicroelectronics STPMIC1 Onkey + +Required properties: + +- compatible = "st,stpmic1-onkey"; +- interrupt-parent: phandle to the parent interrupt controller +- interrupts: interrupt line to use +- interrupt-names = "onkey-falling", "onkey-rising" + onkey-falling: happens when onkey is pressed; IT_PONKEY_F of pmic + onkey-rising: happens when onkey is released; IT_PONKEY_R of pmic + +Optional properties: + +- st,onkey-clear-cc-flag: onkey is able power on after an + over-current shutdown event. +- st,onkey-pu-inactive: onkey pull up is not active +- power-off-time-sec: Duration in seconds which the key should be kept + pressed for device to power off automatically (from 1 to 16 seconds). + see See Documentation/devicetree/bindings/input/keys.txt + +Example: + +onkey { + compatible = "st,stpmic1-onkey"; + interrupt-parent = <&pmic>; + interrupts = ,; + interrupt-names = "onkey-falling", "onkey-rising"; + st,onkey-pwroff-enabled; + st,onkey-long-press-seconds = <10>; +}; -- 1.9.1