From patchwork Fri Apr 26 19:47:45 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luca Weiss X-Patchwork-Id: 10919633 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 27DBD1398 for ; Fri, 26 Apr 2019 19:50:32 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 17BC228E71 for ; Fri, 26 Apr 2019 19:50:32 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0B21F28E72; Fri, 26 Apr 2019 19:50:32 +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=-7.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AAB5928E6E for ; Fri, 26 Apr 2019 19:50:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726757AbfDZTuO (ORCPT ); Fri, 26 Apr 2019 15:50:14 -0400 Received: from mail.z3ntu.xyz ([128.199.32.197]:46824 "EHLO mail.z3ntu.xyz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726400AbfDZTuN (ORCPT ); Fri, 26 Apr 2019 15:50:13 -0400 Received: from localhost.localdomain (80-110-119-101.cgn.dynamic.surfer.at [80.110.119.101]) by mail.z3ntu.xyz (Postfix) with ESMTPSA id 002EBC5309; Fri, 26 Apr 2019 19:50:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=z3ntu.xyz; s=z3ntu; t=1556308210; bh=cWxIdwLO5sI8TQbQdV/dUPitSThiFu9+Fx7tFqperkY=; h=From:To:Cc:Subject:Date; b=VugJoNAyrzbXxb2eRQMOweFZqG2Adl8X7a4dmOxGyRh5cExaP0SPqzqPZ5xpVeQs6 c94HmCDDIHkX2XZ2D2ogmMKbHmlJh5VmwPSIG9M+znvQMjiKudBz0RAaw463t74vn8 SRGrfvV+zI7qMRVKP8eykfLwNbLbAoMvyEUsG8EU= From: Luca Weiss Cc: Dmitry Torokhov , Rob Herring , Mark Rutland , Mauro Carvalho Chehab , Pascal PAILLET-LME , Coly Li , Lee Jones , Xiaotong Lu , Brian Masney , Rob Herring , Baolin Wang , David Brown , linux-arm-msm@vger.kernel.org (open list:ARM/QUALCOMM SUPPORT), linux-input@vger.kernel.org (open list:INPUT (KEYBOARD, MOUSE, JOYSTICK , TOUCHSCREEN)...), devicetree@vger.kernel.org (open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS), linux-kernel@vger.kernel.org (open list), Luca Weiss Subject: [PATCH v5 1/3] dt-bindings: input: add GPIO controllable vibrator Date: Fri, 26 Apr 2019 21:47:45 +0200 Message-Id: <20190426194747.22256-1-luca@z3ntu.xyz> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 To: unlisted-recipients:; (no To-header on input) Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Provide a simple driver for GPIO controllable vibrators. It will be used by the Fairphone 2. Signed-off-by: Luca Weiss Reviewed-by: Rob Herring --- Changes for v5: - Simply compatible property definition - Remove reference to regulator schema .../bindings/input/gpio-vibrator.yaml | 37 +++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 Documentation/devicetree/bindings/input/gpio-vibrator.yaml diff --git a/Documentation/devicetree/bindings/input/gpio-vibrator.yaml b/Documentation/devicetree/bindings/input/gpio-vibrator.yaml new file mode 100644 index 000000000000..903475f52dbd --- /dev/null +++ b/Documentation/devicetree/bindings/input/gpio-vibrator.yaml @@ -0,0 +1,37 @@ +# SPDX-License-Identifier: GPL-2.0 +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/bindings/input/gpio-vibrator.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: GPIO vibrator + +maintainers: + - Luca Weiss + +description: |+ + Registers a GPIO device as vibrator, where the on/off capability is controlled by a GPIO. + +properties: + compatible: + const: gpio-vibrator + + enable-gpios: + maxItems: 1 + + vcc-supply: + description: Regulator that provides power + +required: + - compatible + - enable-gpios + +examples: + - | + #include + + vibrator { + compatible = "gpio-vibrator"; + enable-gpios = <&msmgpio 86 GPIO_ACTIVE_HIGH>; + vcc-supply = <&pm8941_l18>; + };