Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp4183898imm; Tue, 11 Sep 2018 08:10:01 -0700 (PDT) X-Google-Smtp-Source: ANB0VdaQrMgLG9nceBnxVqOZNXSK4KttxOSGE62cwAB+lzfnVAPdwHEabsb53GUT/UGGaajSRy6s X-Received: by 2002:a62:cc41:: with SMTP id a62-v6mr29959025pfg.131.1536678601375; Tue, 11 Sep 2018 08:10:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536678601; cv=none; d=google.com; s=arc-20160816; b=mH+lTrgyM8cGT8xmlThQIe1AQPfE19xOcGLcE5XFUfUlhawY+b/us9kfHSqE5UR47G e74TyFGAzOQl4bCE5mWh68eDYznHf1/g5V8ArROYSfV1ODBPTHf2JvBiYL1I09oCV/W3 BhFoCBacFRuCZMb4rfa8aXU+AouTfge0JP9NYus+7MKNK3hNNpS17Nlt+kQaHWkEgpj4 wKLJwtwxxornkJ8q6pTdk/imLDSP49RTO/YNMABl1A+tz16je1BltWG2pTXArRfkDdwm p7vPsgvj2CFm/p0KLKaLFlKVDF3aYDyptmo4nKjSdpqfztrYTos2MKJs5YvjcnrV/k+Q w+Og== 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; bh=YBcNYkDR+lGpnXWOeFWQgAZD3VAarNPA3QUIHtGwp+8=; b=Pdx07wDPKcmi0ytJhs0/27pDNDqMicA6QsSzeMW/5k3aPLHBH1+rm2Rbg2B3SdlfaH dR07ustL9IHWf5jyVvkpAPM0wkvIM+3ZusQv2ozRtabo1qJQovP6YGVLsRucNtjKdWWQ b2Mx4TQix8ctAaSAF7agn5znsjzE2nSDIfmb3YRp9OFVSnee03QaYLieja9wPio2hVSU klYWpfjRByE6+BQxQ3QK3acFK6ZqC4kDVqkkH1jQGgGY8L47oA+i0AkTq9iRpz4f4MhB aJDs9oN6PBnqlXLLNK3gCa5/fANHHF2pW1Yas4YWR9nKEnc8sjCTXZeSd2xrtQh8gxHH d29Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@synopsys.com header.s=mail header.b=SszYo6uq; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=synopsys.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x1-v6si20634154plb.135.2018.09.11.08.09.42; Tue, 11 Sep 2018 08:10:01 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@synopsys.com header.s=mail header.b=SszYo6uq; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=synopsys.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727346AbeIKUJP (ORCPT + 99 others); Tue, 11 Sep 2018 16:09:15 -0400 Received: from smtprelay.synopsys.com ([198.182.60.111]:56898 "EHLO smtprelay.synopsys.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726622AbeIKUJP (ORCPT ); Tue, 11 Sep 2018 16:09:15 -0400 Received: from mailhost.synopsys.com (mailhost2.synopsys.com [10.13.184.66]) by smtprelay.synopsys.com (Postfix) with ESMTP id D86CF10C1206; Tue, 11 Sep 2018 08:09:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=synopsys.com; s=mail; t=1536678572; bh=B1Yp+Fn9sk/lH8XlHw5qCW/mIZmO/y5sFNKuQHW6Zz8=; h=From:To:Cc:Subject:Date:From; b=SszYo6uqX3olNJNJgRKW8oNsyidn61JIMyi4o0orJAnIQKbdGxKYv4jkVcjNwex7h 4zKV5oYyGTtH1kUZkA8Kk3fR1vmqHPOpFXtrU9k7IImuZmT4A9upBJO4PBgQvr9Fiz PvSF2JvEorTw7jX65oBkifUDWxtha5N0d51ax7O9/JwuXj3F+aU2hLi6+M/gYRPLiW O1WMGEhr4nW1wFWZbX74wrzyGu05pkP2piEd/EaXWUfIgsGQYAI6m6HsFKR8WZpUET +c//nWVwkT4b7tAyT1tI47K8fZM1rhpmZUmlCwysKkCxy9yRQDUeotQpN/5E6g6Ot+ 9Q/vWWPUozj6A== Received: from paltsev-e7480.internal.synopsys.com (paltsev-e7480.internal.synopsys.com [10.121.3.37]) by mailhost.synopsys.com (Postfix) with ESMTP id 545293A79; Tue, 11 Sep 2018 08:09:28 -0700 (PDT) From: Eugeniy Paltsev To: linux-snps-arc@lists.infradead.org, linux-gpio@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Vineet Gupta , Alexey Brodkin , Linus Walleij , Rob Herring , devicetree@vger.kernel.org, Mark Rutland , Eugeniy Paltsev Subject: [PATCH v3 0/2] GPIO: add single-register GPIO via CREG driver Date: Tue, 11 Sep 2018 18:09:23 +0300 Message-Id: <20180911150925.19460-1-Eugeniy.Paltsev@synopsys.com> X-Mailer: git-send-email 2.14.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add single-register MMIO GPIO driver for complex cases where only several fields in register belong to GPIO lines and each GPIO line owns a field with different length and on/off value. Such CREG GPIOs are used in Synopsys AXS10x and HSDK boards. Changes v2->v3: * Move parameters into a lookup table instead of device tree. * Use the ngpios attribute for instead of snps,ngpios. Eugeniy Paltsev (2): GPIO: add single-register GPIO via CREG driver dt-bindings: Document the Synopsys GPIO via CREG bindings .../devicetree/bindings/gpio/snps,creg-gpio.txt | 18 ++ MAINTAINERS | 6 + drivers/gpio/Kconfig | 10 + drivers/gpio/Makefile | 1 + drivers/gpio/gpio-creg-snps.c | 212 +++++++++++++++++++++ 5 files changed, 247 insertions(+) create mode 100644 Documentation/devicetree/bindings/gpio/snps,creg-gpio.txt create mode 100644 drivers/gpio/gpio-creg-snps.c -- 2.14.4