From patchwork Tue Jan 30 12:07:42 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Baolin Wang X-Patchwork-Id: 867475 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; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="JSIhNGKF"; dkim-atps=neutral Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 3zW4tg1nl6z9s7M for ; Tue, 30 Jan 2018 23:09:31 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751546AbeA3MI7 (ORCPT ); Tue, 30 Jan 2018 07:08:59 -0500 Received: from mail-pf0-f195.google.com ([209.85.192.195]:43724 "EHLO mail-pf0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751798AbeA3MI5 (ORCPT ); Tue, 30 Jan 2018 07:08:57 -0500 Received: by mail-pf0-f195.google.com with SMTP id y26so8704283pfi.10 for ; Tue, 30 Jan 2018 04:08:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=Fw+oTKOcD9WPc+Cak6Evz27nASVE/9LUbVzUjk3BZCU=; b=JSIhNGKF/rZQjpkDSkPKuMcbTXZ+9V2D4ufiVuyF0O5gE2TRaWyc8ROlX7EWW8bJu0 oNrLEhWQsQr6n291W6wSMum7FvHJF8C1aWJLMCy/V7vpinkXo0T41LqEp/zDwxUW9O46 84QDxpjuc+ErC8H6L0d4OZOMbBgyaBbZGK9BY= 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; bh=Fw+oTKOcD9WPc+Cak6Evz27nASVE/9LUbVzUjk3BZCU=; b=VWVRmDSRVPTHowIBNAiLp+bd+BeVFr5LuXmozjVP30WaScY15TKS6oN1c9KO8TeCko eUKQUKqMW+BwIvgKk0svjoPYbhe/+QfOwsXePzuPwTjKJVvTeYBJHunptqdQ7XORhyPV gDkDPejS72R/Uxhsd62tUwyjyA9zQWAPPlonVMnFSUJqAxEm9ZZuVNHykqTXJcBj0YmI 7Nsq18fSfU4tH4OU9AMNye/KBWqZlPp1RvG0XhM6+Is+H6uYMG4BRzIzKIcvng4Yi1Qx f2Pk7EGFSToBH+EOK4b3W1wXuYWDwwqUakCTRD5vlAihpbRH+xhqfMEwUOuT8C/DIGcY dM5w== X-Gm-Message-State: AKwxyterkZvUK7BkE+HO98nOVfYC6qPRoZFb9Vxk6caAQ5Ni+M2tgbfk 6YtQfKqkMkGW6VWXwRQmVAs16g== X-Google-Smtp-Source: AH8x226wOjuwZB1FibTUmY3c7NfMZUVs+Yjw4/mW/TNIyAMtAhfUTZdQZPRjYlVo+mPOhibb1aWaDA== X-Received: by 10.98.59.80 with SMTP id i77mr30418301pfa.146.1517314136463; Tue, 30 Jan 2018 04:08:56 -0800 (PST) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.82]) by smtp.gmail.com with ESMTPSA id y1sm22961534pge.78.2018.01.30.04.08.53 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 30 Jan 2018 04:08:55 -0800 (PST) From: Baolin Wang To: linus.walleij@linaro.org, robh+dt@kernel.org, mark.rutland@arm.com Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, broonie@kernel.org, baolin.wang@linaro.org Subject: [PATCH 1/2] dt-bindings: gpio: Add Spreadtrum GPIO controller documentation Date: Tue, 30 Jan 2018 20:07:42 +0800 Message-Id: <2834309f69a1ec37b84a33f153a3d0b90336bcc6.1517313987.git.baolin.wang@linaro.org> X-Mailer: git-send-email 1.7.9.5 Sender: linux-gpio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org This patch adds the device tree bindings for the Spreadtrum GPIO controller. The gpios will be supported by the GPIO generic library. Signed-off-by: Baolin Wang --- .../devicetree/bindings/gpio/gpio-sprd.txt | 28 ++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 Documentation/devicetree/bindings/gpio/gpio-sprd.txt diff --git a/Documentation/devicetree/bindings/gpio/gpio-sprd.txt b/Documentation/devicetree/bindings/gpio/gpio-sprd.txt new file mode 100644 index 0000000..eca97d4 --- /dev/null +++ b/Documentation/devicetree/bindings/gpio/gpio-sprd.txt @@ -0,0 +1,28 @@ +Spreadtrum GPIO controller bindings + +The controller's registers are organized as sets of sixteen 16-bit +registers with each set controlling a bank of up to 16 pins. A single +interrupt is shared for all of the banks handled by the controller. + +Required properties: +- compatible: Should be "sprd,sc9860-gpio". +- reg: Define the base and range of the I/O address space containing +the GPIO controller registers. +- gpio-controller: Marks the device node as a GPIO controller. +- #gpio-cells: Should be <2>. The first cell is the gpio number and +the second cell is used to specify optional parameters. +- interrupt-controller: Marks the device node as an interrupt controller. +- #interrupt-cells: Should be <2>. Specifies the number of cells needed +to encode interrupt source. +- interrupts: Should be the port interrupt shared by all the gpios. + +Example: + ap_gpio: gpio@40280000 { + compatible = "sprd,sc9860-gpio"; + reg = <0 0x40280000 0 0x1000>; + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + interrupts = ; + };