From: Soren Brinkmann <soren.brinkmann@xilinx.com>
To: Linus Walleij <linus.walleij@linaro.org>
Cc: "Sören Brinkmann" <soren.brinkmann@xilinx.com>,
"Michal Simek" <michal.simek@xilinx.com>,
linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
"Steffen Trumtrar" <s.trumtrar@pengutronix.de>
Subject: [PATCH RFC v2 3/8] pinctrl: pinconf-generic: Add parameter 'IO standard'
Date: Thu, 16 Oct 2014 10:11:30 -0700 [thread overview]
Message-ID: <1413479495-14206-4-git-send-email-soren.brinkmann@xilinx.com> (raw)
In-Reply-To: <1413479495-14206-1-git-send-email-soren.brinkmann@xilinx.com>
For HW that can select the IO standard for pins, add the infrastructure
in pinconf generic to parse this parameter.
Signed-off-by: Soren Brinkmann <soren.brinkmann@xilinx.com>
---
Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt | 3 +++
drivers/pinctrl/pinconf-generic.c | 2 ++
include/linux/pinctrl/pinconf-generic.h | 4 ++++
3 files changed, 9 insertions(+)
diff --git a/Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt b/Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt
index 98eb94d91a1c..862c4fe17d04 100644
--- a/Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt
+++ b/Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt
@@ -184,6 +184,7 @@ low-power-disable - disable low power mode
output-low - set the pin to output mode with low level
output-high - set the pin to output mode with high level
slew-rate - set the slew rate
+io-standard - set the IO standard
For example:
@@ -215,5 +216,7 @@ arguments are described below.
- input-debounce takes the debounce time in usec as argument
or 0 to disable debouncing
+- io-standard takes a driver specific argument to select an IO standard
+
More in-depth documentation on these parameters can be found in
<include/linux/pinctrl/pinconfig-generic.h>
diff --git a/drivers/pinctrl/pinconf-generic.c b/drivers/pinctrl/pinconf-generic.c
index e28ef957ca2d..17ac8f00e16b 100644
--- a/drivers/pinctrl/pinconf-generic.c
+++ b/drivers/pinctrl/pinconf-generic.c
@@ -58,6 +58,7 @@ static struct pin_config_item conf_items[] = {
PCONFDUMP(PIN_CONFIG_SLEW_RATE, "slew rate", NULL, true),
PCONFDUMP(PIN_CONFIG_LOW_POWER_MODE, "pin low power", "mode", true),
PCONFDUMP(PIN_CONFIG_OUTPUT, "pin output", "level", true),
+ PCONFDUMP(PIN_CONFIG_IOSTANDARD, "io standard", NULL, true),
};
void pinconf_generic_dump_pin(struct pinctrl_dev *pctldev,
@@ -181,6 +182,7 @@ static struct pinconf_generic_dt_params dt_params[] = {
{ "output-low", PIN_CONFIG_OUTPUT, 0, },
{ "output-high", PIN_CONFIG_OUTPUT, 1, },
{ "slew-rate", PIN_CONFIG_SLEW_RATE, 0},
+ { "io-standard", PIN_CONFIG_IOSTANDARD, 0},
};
/**
diff --git a/include/linux/pinctrl/pinconf-generic.h b/include/linux/pinctrl/pinconf-generic.h
index d578a60eff23..dd1d3251fb93 100644
--- a/include/linux/pinctrl/pinconf-generic.h
+++ b/include/linux/pinctrl/pinconf-generic.h
@@ -92,6 +92,9 @@
* @PIN_CONFIG_END: this is the last enumerator for pin configurations, if
* you need to pass in custom configurations to the pin controller, use
* PIN_CONFIG_END+1 as the base offset.
+ * @PIN_CONFIG_IOSTANDARD: if the pin can select an IO standard, the argument to
+ * this parameter (on a custom format) tells the driver which alternative
+ * IO standard to use.
*/
enum pin_config_param {
PIN_CONFIG_BIAS_DISABLE,
@@ -112,6 +115,7 @@ enum pin_config_param {
PIN_CONFIG_SLEW_RATE,
PIN_CONFIG_LOW_POWER_MODE,
PIN_CONFIG_OUTPUT,
+ PIN_CONFIG_IOSTANDARD,
PIN_CONFIG_END = 0x7FFF,
};
--
2.1.2.1.g5e69ed6
next prev parent reply other threads:[~2014-10-16 17:13 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-16 17:11 [PATCH RFC v2 0/8] Pinctrl support for Zynq Soren Brinkmann
2014-10-16 17:11 ` [PATCH RFC v2 1/8] pinctrl: Add driver " Soren Brinkmann
2014-10-28 14:53 ` Linus Walleij
2014-10-28 16:14 ` Sören Brinkmann
2014-10-28 15:16 ` Lothar Waßmann
2014-10-28 16:37 ` Sören Brinkmann
2014-10-29 4:49 ` Lothar Waßmann
2014-10-29 14:12 ` Sören Brinkmann
2014-10-30 8:16 ` Lothar Waßmann
2014-11-02 17:22 ` Sören Brinkmann
2014-10-16 17:11 ` [PATCH RFC v2 2/8] pinctrl: pinconf-generic: Add flag to print arguments Soren Brinkmann
2014-10-28 14:55 ` Linus Walleij
2014-10-16 17:11 ` Soren Brinkmann [this message]
2014-10-28 14:59 ` [PATCH RFC v2 3/8] pinctrl: pinconf-generic: Add parameter 'IO standard' Linus Walleij
2014-10-28 16:07 ` Sören Brinkmann
2014-10-31 8:19 ` Linus Walleij
2014-10-16 17:11 ` [PATCH RFC v2 4/8] pinctrl: zynq: Support IO standard property Soren Brinkmann
2014-10-16 17:11 ` [PATCH RFC v2 5/8] pinctrl: zynq: Support low power mode property Soren Brinkmann
2014-10-16 17:11 ` [PATCH RFC v2 6/8] pinctrl: pinconf-generic: Infer map type from DT property Soren Brinkmann
2014-10-16 17:11 ` [PATCH RFC v2 7/8] pinctrl: zynq: Use generic map_all function Soren Brinkmann
2014-10-16 17:11 ` [PATCH RFC v2 8/8] ARM: zynq: DT: Add pinctrl information Soren Brinkmann
2014-10-21 5:54 ` Michal Simek
2014-10-28 15:05 ` Linus Walleij
2014-10-28 16:03 ` Sören Brinkmann
2014-10-31 8:17 ` Linus Walleij
2014-10-31 16:57 ` Sören Brinkmann
2014-10-31 17:36 ` Linus Walleij
2014-10-31 17:40 ` Sören Brinkmann
2014-11-02 20:20 ` Sören Brinkmann
2014-11-03 14:40 ` Linus Walleij
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=1413479495-14206-4-git-send-email-soren.brinkmann@xilinx.com \
--to=soren.brinkmann@xilinx.com \
--cc=linus.walleij@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=michal.simek@xilinx.com \
--cc=s.trumtrar@pengutronix.de \
/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®