From patchwork Thu Feb 8 08:01:42 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\(Exiting\) Baolin Wang" X-Patchwork-Id: 127269 Delivered-To: patch@linaro.org Received: by 10.46.124.24 with SMTP id x24csp1247803ljc; Thu, 8 Feb 2018 00:02:13 -0800 (PST) X-Google-Smtp-Source: AH8x227BHm0WV3bJcodFJpIJWKQa4quQBwtJOEA4Zr0UWyNojKLpktplkk2g/K6zXx0MPM1gA8Me X-Received: by 2002:a17:902:8491:: with SMTP id c17-v6mr8791851plo.105.1518076933578; Thu, 08 Feb 2018 00:02:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518076933; cv=none; d=google.com; s=arc-20160816; b=YUwo1mDmq4YkzZbJ+g+h37gl2QF2u8+PUMnY+dqv0wicR7gcg/DUI19L1xv+yXZrSX iU7t8EEXOMK1yM60tPYEq2JNADo5aouOVSr03PmuH4oU9vS2l7ZF8MPBsc50xWacuRoY 5ANNWrR2R6HTkMTvFfY73cghM1axrpJGti3dZwPFg4G0u64d6ckJ+H4GqyQL746qhvyW YJc8X0ULx+3mpHZ44ZWMDqjfPNeGtnQh1FDAoNpXbRvFr/2qxdo2ZoA4TnrWG0EEiEmt 9PGw79/BXHIf7l3OYtUuX/WDQP3ggG0j1hWxqqOWx+bHCr0RyNK/SjyU4fc8OzrNwiVY aD+Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=dV1iv8DAChmxt+CSJU9bTk0jOi6qOd4LirHcj54bRk0=; b=t/Kc2Z3sK16yA7vg5IJyXmvT28nn8z0CPYfnZ/yWJj6y9Sicem3CILemisCwrB1PDF fZh//htV/C9wxNlGxphRQdCy2vmCsZybKrfhj2a1Xacchh9qaME8XLUtox0m77cwJ+Mz fWRc079Vn4Xn4oJbWHxQIkNGCnw+UuZFqzrn2MpYTYLUVnOm0seFsIVmSOLXxlfj5ZZk B6/hixRJAoP73r4n4NYlMZsdo4UGRzbz10ksekmGLd1b3XESZdfQW8kLZwKyPg3XuzMc pvrEpKW5i2sFqUbB7sunJvTiImEZ7Fs9VDu8YVHlbJAJ/BCmSWwz2fUodGsgyUtQhTRs zMGw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=Xp+ltz8t; spf=pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h9si2087485pgq.683.2018.02.08.00.02.13; Thu, 08 Feb 2018 00:02:13 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=Xp+ltz8t; spf=pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750876AbeBHICM (ORCPT + 5 others); Thu, 8 Feb 2018 03:02:12 -0500 Received: from mail-pg0-f66.google.com ([74.125.83.66]:45769 "EHLO mail-pg0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750815AbeBHICL (ORCPT ); Thu, 8 Feb 2018 03:02:11 -0500 Received: by mail-pg0-f66.google.com with SMTP id m136so1346446pga.12 for ; Thu, 08 Feb 2018 00:02:11 -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=kbjuYO3tEDBWwTIaqQoLiptgd0PYHUDE6C3cCgyqhEU=; b=Xp+ltz8t3TwTXkHNx09p3mrVpMwLSDFSLojlj4Jehk0d4AIe1RrM3GibgisPrY7Tu9 9ONrG7W7ab4zHm6TH/n8dc497Hdkg4z7RLjmlRRREEr6e07YuDiGPXAv8tpBkbwK3Ojm PxQRLnn9hPKvGjl5ehec5qVyLQ54YJmDxQFS0= 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=kbjuYO3tEDBWwTIaqQoLiptgd0PYHUDE6C3cCgyqhEU=; b=SlnGtWskP+13T24HvFQ/+me2YCUaoSv3QfQCUodAhU1qmLSur6oW2/+60Ysshwre6Z tvIvcb2VFUFygeEXAm/gyqmsAokKvom5heC4MhAtwAZPa8l5XzaEgcCWoK6kTZwIkpbe w7G7ACu5ihz5bZ+GtPFyJHa0apCeNipYd2XvvT/hiNjVRyPorqcOtCdCYJ/QkNbfNX+N 4hQ2lrzUoHHYa59YO9HGnfHUC5eeo+jL/+Kp4mkymuiBZ+jJjnXj48s86SScQvKUvP65 2t6Sg9+3yoewm//okDXb7KSSarLKnD9UL42mne7PtD2wDaiDE5cdadACK66SB4Vg5/vh yaDQ== X-Gm-Message-State: APf1xPCmEsJ7IP08JNbpb2fiwePM3U6pkbL5YuinG3JSfRGH3cn+tXzU V8PWdM5bqVF6jIc5LYHU0s5HJtYso4w= X-Received: by 10.99.113.11 with SMTP id m11mr7231601pgc.57.1518076931171; Thu, 08 Feb 2018 00:02:11 -0800 (PST) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.82]) by smtp.gmail.com with ESMTPSA id e189sm8136726pfa.4.2018.02.08.00.02.08 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 08 Feb 2018 00:02:10 -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, andy.shevchenko@gmail.com Subject: [PATCH 1/2] dt-bindings: gpio: Add Spreadtrum EIC controller documentation Date: Thu, 8 Feb 2018 16:01:42 +0800 Message-Id: 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 EIC controller. The EIC can be recognized as one special type of GPIO, which can only be used as input. Signed-off-by: Baolin Wang --- .../devicetree/bindings/gpio/gpio-eic-sprd.txt | 51 ++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 Documentation/devicetree/bindings/gpio/gpio-eic-sprd.txt -- 1.7.9.5 -- To unsubscribe from this list: send the line "unsubscribe linux-gpio" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/Documentation/devicetree/bindings/gpio/gpio-eic-sprd.txt b/Documentation/devicetree/bindings/gpio/gpio-eic-sprd.txt new file mode 100644 index 0000000..34f194f --- /dev/null +++ b/Documentation/devicetree/bindings/gpio/gpio-eic-sprd.txt @@ -0,0 +1,51 @@ +Spreadtrum EIC controller bindings + +The EIC is the abbreviation of external interrupt controller, which +is only can be used as input mode. The EIC controller includes 4 +sub-modules: EIC-Debounce, EIC-Latch, EIC-Async, EIC-Sync. + +The EIC-debounce sub-module provides up to 8 source input signal +connection. A debounce machanism is used to capture input signal's +stable status (ms grade) and a single-trigger mechanism is introduced +into this sub-module to enhance the input event detection reliability. +In addition, this sub-module's clock can be shut-off automatically to +reduce power dissipation. The debounce range is from 1ms to 4s with +the step of 1ms. If the input signal is shorter than 1ms, it will be +omitted as this sub-module. + +The EIC-latch sub-module is used to latch some special input signal +and send interrupts to MCU core, and it can provide up to 8 latch +source input signal connection. + +The EIC-async sub-module uses 32k clock to capture short signal (us +grade) to generate interrupt to MCU by level or edge trigger. + +The EIC-sync is similar with GPIO's input function. + +Required properties: +- compatible: Should be one of the following: + "sprd,sc9860-eic-debounce", + "sprd,sc9860-eic-latch", + "sprd,sc9860-eic-async", + "sprd,sc9860-eic-sync", + "sprd,sc27xx-eic-debounce". +- 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: + eic_debounce: eic@40210000 { + compatible = "sprd,sc9860-eic-debounce"; + reg = <0 0x40210000 0 0x80>; + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + interrupts = ; + };