From patchwork Fri Jun 28 05:20:36 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Harish Jenny K N X-Patchwork-Id: 1123934 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=linux-gpio-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=mentor.com Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 45ZlV40Wscz9s9h for ; Fri, 28 Jun 2019 15:21:00 +1000 (AEST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726843AbfF1FU6 (ORCPT ); Fri, 28 Jun 2019 01:20:58 -0400 Received: from relay1.mentorg.com ([192.94.38.131]:42325 "EHLO relay1.mentorg.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726816AbfF1FU6 (ORCPT ); Fri, 28 Jun 2019 01:20:58 -0400 Received: from nat-ies.mentorg.com ([192.94.31.2] helo=svr-ies-mbx-01.mgc.mentorg.com) by relay1.mentorg.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-SHA384:256) id 1hgjJf-0003Zb-Pz from Harish_Kandiga@mentor.com ; Thu, 27 Jun 2019 22:20:55 -0700 Received: from hkandiga-VirtualBox.ina-wifi.mentorg.com (137.202.0.90) by svr-ies-mbx-01.mgc.mentorg.com (139.181.222.1) with Microsoft SMTP Server (TLS) id 15.0.1320.4; Fri, 28 Jun 2019 06:20:51 +0100 From: Harish Jenny K N To: Linus Walleij , Bartosz Golaszewski CC: , Harish Jenny K N , Balasubramani Vivekanandan Subject: [PATCH V4 2/2] gpio: inverter: document the inverter bindings Date: Fri, 28 Jun 2019 10:50:36 +0530 Message-ID: <1561699236-18620-3-git-send-email-harish_kandiga@mentor.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1561699236-18620-1-git-send-email-harish_kandiga@mentor.com> References: <1561699236-18620-1-git-send-email-harish_kandiga@mentor.com> MIME-Version: 1.0 X-Originating-IP: [137.202.0.90] X-ClientProxiedBy: svr-ies-mbx-06.mgc.mentorg.com (139.181.222.6) To svr-ies-mbx-01.mgc.mentorg.com (139.181.222.1) Sender: linux-gpio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org Document the device tree binding for the inverter gpio controller to configure the polarity of the gpio pins used by the consumers. Signed-off-by: Harish Jenny K N --- .../devicetree/bindings/gpio/gpio-inverter.txt | 29 ++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 Documentation/devicetree/bindings/gpio/gpio-inverter.txt -- 2.7.4 diff --git a/Documentation/devicetree/bindings/gpio/gpio-inverter.txt b/Documentation/devicetree/bindings/gpio/gpio-inverter.txt new file mode 100644 index 0000000..8bb6b2e --- /dev/null +++ b/Documentation/devicetree/bindings/gpio/gpio-inverter.txt @@ -0,0 +1,29 @@ +GPIO-INVERTER +====== +This binding defines the gpio-inverter. The gpio-inverter is a driver that +allows to properly describe the gpio polarities on the hardware. + +Please refer to gpio.txt for generic information regarding GPIO bindings. + +Required properties: +- compatible : "gpio-inverter". +- gpio-controller: Marks the port as GPIO controller. +- #gpio-cells: One. This is the pin number. +- inverted-gpios: Array of GPIO pins required from consumers, whose polarity + has to be inverted in the driver. +Note: gpio flag should be set as GPIO_ACTIVE_HIGH. Using GPIO_ACTICE_LOW will +cause double inversion. + +Optional properties: +- gpio-line-names: Refer to gpio.txt for details regarding this property. + +Example: + +gpio_inv: gpio-inv { + compatible = "gpio-inverter"; + gpio-controller; + #gpio-cells = <1>; + inverted-gpios = <&gpio5 24 GPIO_ACTIVE_HIGH>, + <&gpio7 0 GPIO_ACTIVE_HIGH>, <&gpio7 1 GPIO_ACTIVE_HIGH>; + gpio-line-names = "JTAG_DNL_EN", "lvds-pwrdwn", "lcd-on"; +};