From: Srinivas Neeli <srinivas.neeli@xilinx.com>
To: linus.walleij@linaro.org, bgolaszewski@baylibre.com,
michal.simek@xilinx.com, shubhrajyoti.datta@xilinx.com
Cc: linux-gpio@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, git@xilinx.com
Subject: [PATCH 7/8] gpio: zynq: Add pmc gpio support
Date: Thu, 26 Dec 2019 17:42:17 +0530 [thread overview]
Message-ID: <1577362338-28744-8-git-send-email-srinivas.neeli@xilinx.com> (raw)
In-Reply-To: <1577362338-28744-1-git-send-email-srinivas.neeli@xilinx.com>
From: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
Add PMC gpio support.
Only bank 0,1, 3 and 4 are connected to the multiplexed Input output
pins. Bank 0 and 1 to mio and bank 3 and 4 to extended multiplexed input
output pins.
Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
---
drivers/gpio/gpio-zynq.c | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/drivers/gpio/gpio-zynq.c b/drivers/gpio/gpio-zynq.c
index 04e7a993be8b..674416a40117 100644
--- a/drivers/gpio/gpio-zynq.c
+++ b/drivers/gpio/gpio-zynq.c
@@ -23,6 +23,7 @@
#define ZYNQ_GPIO_MAX_BANK 4
#define ZYNQMP_GPIO_MAX_BANK 6
#define VERSAL_GPIO_MAX_BANK 4
+#define PMC_GPIO_MAX_BANK 5
#define VERSAL_UNUSED_BANKS 2
#define ZYNQ_GPIO_BANK0_NGPIO 32
@@ -815,6 +816,20 @@ static const struct zynq_platform_data versal_gpio_def = {
.bank_max[3] = 57, /* Bank 3 is connected to FMIOs (32 pins) */
};
+static const struct zynq_platform_data pmc_gpio_def = {
+ .label = "pmc_gpio",
+ .ngpio = 116,
+ .max_bank = PMC_GPIO_MAX_BANK,
+ .bank_min[0] = 0,
+ .bank_max[0] = 25, /* 0 to 25 are connected to MIOs (26 pins) */
+ .bank_min[1] = 26,
+ .bank_max[1] = 51, /* Bank 1 are connected to MIOs (26 pins) */
+ .bank_min[3] = 52,
+ .bank_max[3] = 83, /* Bank 3 is connected to EMIOs (32 pins) */
+ .bank_min[4] = 84,
+ .bank_max[4] = 115, /* Bank 4 is connected to EMIOs (32 pins) */
+};
+
static const struct zynq_platform_data zynqmp_gpio_def = {
.label = "zynqmp_gpio",
.quirks = GPIO_QUIRK_DATA_RO_BUG,
@@ -853,6 +868,7 @@ static const struct of_device_id zynq_gpio_of_match[] = {
{ .compatible = "xlnx,zynq-gpio-1.0", .data = &zynq_gpio_def },
{ .compatible = "xlnx,zynqmp-gpio-1.0", .data = &zynqmp_gpio_def },
{ .compatible = "xlnx,versal-gpio-1.0", .data = &versal_gpio_def },
+ { .compatible = "xlnx,pmc-gpio-1.0", .data = &pmc_gpio_def },
{ /* end of table */ }
};
MODULE_DEVICE_TABLE(of, zynq_gpio_of_match);
--
2.7.4
next prev parent reply other threads:[~2019-12-26 12:13 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-26 12:12 [PATCH 0/8] gpio: zynq: Update on gpio-zynq driver Srinivas Neeli
2019-12-26 12:12 ` [PATCH 1/8] gpio: zynq: Fix for bug in zynq_gpio_restore_context API Srinivas Neeli
2020-01-07 10:25 ` Linus Walleij
2019-12-26 12:12 ` [PATCH 2/8] gpio: zynq: protect direction in/out with a spinlock Srinivas Neeli
2020-01-02 17:40 ` Bartosz Golaszewski
2019-12-26 12:12 ` [PATCH 3/8] dt-bindings: gpio: Add binding for Versal gpio Srinivas Neeli
2019-12-26 12:12 ` [PATCH 4/8] devicetree-binding: Add pmc gpio node Srinivas Neeli
2019-12-26 12:12 ` [PATCH 5/8] gpio: zynq: Add Versal support Srinivas Neeli
2020-01-02 17:41 ` Bartosz Golaszewski
2019-12-26 12:12 ` [PATCH 6/8] gpio: zynq: Disable the irq if it is not a wakeup source Srinivas Neeli
2019-12-26 12:12 ` Srinivas Neeli [this message]
2020-01-02 17:55 ` [PATCH 7/8] gpio: zynq: Add pmc gpio support Bartosz Golaszewski
2019-12-26 12:12 ` [PATCH 8/8] gpio: zynq: Remove error prints in EPROBE_DEFER Srinivas Neeli
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1577362338-28744-8-git-send-email-srinivas.neeli@xilinx.com \
--to=srinivas.neeli@xilinx.com \
--cc=bgolaszewski@baylibre.com \
--cc=git@xilinx.com \
--cc=linus.walleij@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=michal.simek@xilinx.com \
--cc=shubhrajyoti.datta@xilinx.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®