From patchwork Fri Mar 4 18:58:44 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Davis X-Patchwork-Id: 592180 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 6FC84140216 for ; Sat, 5 Mar 2016 05:59:26 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752956AbcCDS7E (ORCPT ); Fri, 4 Mar 2016 13:59:04 -0500 Received: from bear.ext.ti.com ([192.94.94.41]:59394 "EHLO bear.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751414AbcCDS7C (ORCPT ); Fri, 4 Mar 2016 13:59:02 -0500 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by bear.ext.ti.com (8.13.7/8.13.7) with ESMTP id u24IwoYC021539; Fri, 4 Mar 2016 12:58:50 -0600 Received: from DFLE72.ent.ti.com (dfle72.ent.ti.com [128.247.5.109]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id u24IwoJo020327; Fri, 4 Mar 2016 12:58:50 -0600 Received: from dflp33.itg.ti.com (10.64.6.16) by DFLE72.ent.ti.com (128.247.5.109) with Microsoft SMTP Server id 14.3.224.2; Fri, 4 Mar 2016 12:58:50 -0600 Received: from legion.dal.design.ti.com (legion.dal.design.ti.com [128.247.22.53]) by dflp33.itg.ti.com (8.14.3/8.13.8) with ESMTP id u24IwofQ009614; Fri, 4 Mar 2016 12:58:50 -0600 Received: from localhost (uda0226330.am.dhcp.ti.com [128.247.83.30]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id u24Iwn922195; Fri, 4 Mar 2016 12:58:49 -0600 (CST) From: "Andrew F. Davis" To: Linus Walleij , Alexandre Courbot , Rob Herring , Pawel Moll , Mark Rutland , Ian Campbell , Kumar Gala CC: , , , "Andrew F. Davis" Subject: [PATCH v3] dt-bindings: GPIO: Add generic serializer binding Date: Fri, 4 Mar 2016 12:58:44 -0600 Message-ID: <1457117924-7014-1-git-send-email-afd@ti.com> X-Mailer: git-send-email 2.7.2 MIME-Version: 1.0 Sender: linux-gpio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org Add binding for generic parallel-in/serial-out shift register devices used as GPIO. Signed-off-by: Andrew F. Davis Acked-by: Rob Herring --- The driver was taken but it looks like this might have been lost, anyway I've added a dual-string example as requested. .../devicetree/bindings/gpio/gpio-pisosr.txt | 34 ++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 Documentation/devicetree/bindings/gpio/gpio-pisosr.txt diff --git a/Documentation/devicetree/bindings/gpio/gpio-pisosr.txt b/Documentation/devicetree/bindings/gpio/gpio-pisosr.txt new file mode 100644 index 0000000..dab8c9f --- /dev/null +++ b/Documentation/devicetree/bindings/gpio/gpio-pisosr.txt @@ -0,0 +1,34 @@ +Generic Parallel-in/Serial-out Shift Register GPIO Driver + +This binding describes generic parallel-in/serial-out shift register +devices that can be used for GPI (General Purpose Input). This includes +SN74165 serial-out shift registers and the SN65HVS88x series of +industrial serializers. + +Required properties: + - compatible : Should be "pisosr-gpio". + - gpio-controller : Marks the device node as a GPIO controller. + - #gpio-cells : Should be two. For consumer use see gpio.txt. + +Optional properties: + - ngpios : Number of GPIO lines, default is 8. + - load-gpios : GPIO pin specifier attached to load enable, this + pin is pulsed before reading from the device to + load input pin values into the the device. + +For other required and optional properties of SPI slave +nodes please refer to ../spi/spi-bus.txt. + +Example: + + gpio@0 { + compatible = "ti,sn65hvs882", "pisosr-gpio"; + gpio-controller; + #gpio-cells = <2>; + + load-gpios = <&gpio2 23 GPIO_ACTIVE_LOW>; + + reg = <0>; + spi-max-frequency = <1000000>; + spi-cpol; + };