From: "Heiko Stübner" <heiko@sntech.de> To: Linus Walleij <linus.walleij@linaro.org> Cc: "linux-arm-kernel@lists.infradead.org" <linux-arm-kernel@lists.infradead.org>, "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>, Grant Likely <grant.likely@linaro.org>, rob.herring@calxeda.com, devicetree-discuss@lists.ozlabs.org, James Hogan <james.hogan@imgtec.com>, Laurent Pinchart <laurent.pinchart@ideasonboard.com> Subject: [PATCH 2/5] pinctrl: clarify some dt pinconfig options Date: Fri, 14 Jun 2013 17:42:49 +0200 [thread overview] Message-ID: <201306141742.49923.heiko@sntech.de> (raw) In-Reply-To: <201306141741.46077.heiko@sntech.de> The bias-pull-* options use values > 0 to indicate that the pull should be activated and optionally also indicate the strength of the pull. Therefore use an default value of 1 for these options. Split the low-power-mode option into low-power-enable and -disable. Update the documentation to describe the param arguments better. Wrong default options Reported-by: James Hogan <james.hogan@imgtec.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> --- .../bindings/pinctrl/pinctrl-bindings.txt | 22 +++++++++++++++++++- drivers/pinctrl/pinconf-generic.c | 9 ++++---- 2 files changed, 26 insertions(+), 5 deletions(-) diff --git a/Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt b/Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt index ef7cd57..2d730e3 100644 --- a/Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt +++ b/Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt @@ -158,9 +158,29 @@ input-schmitt - run in schmitt-trigger mode with hysteresis X input-debounce - debounce mode with debound time X power-source - select power source X slew-rate - use slew-rate X -low-power-mode - low power mode +low-power-enable - enable low power mode +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 +Arguments for parameters: + +- bias-pull-up, -down and -pin-default take as optional argument 0 to disable + the pull, on hardware supporting it the pull strength in Ohm. bias-disable + will also disable any active pull. + +- drive-strength takes as argument the target strength in mA. + +- input-schmitt takes as argument the adjustable hysteresis in a + driver-specific format + +- input-debounce takes the debounce time as argument or 0 to disable debouncing + +- power-source argument is the custom value describing the source to select + +- slew-rate takes as argument the target rate in a driver-specific format + +All parameters not listed here, do not take an argument. + 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 d3c693c..dcf0371 100644 --- a/drivers/pinctrl/pinconf-generic.c +++ b/drivers/pinctrl/pinconf-generic.c @@ -152,9 +152,9 @@ static struct pinconf_generic_dt_params dt_params[] = { { "bias-disable", PIN_CONFIG_BIAS_DISABLE, 0 }, { "bias-high-impedance", PIN_CONFIG_BIAS_HIGH_IMPEDANCE, 0 }, { "bias-bus-hold", PIN_CONFIG_BIAS_BUS_HOLD, 0 }, - { "bias-pull-up", PIN_CONFIG_BIAS_PULL_UP, 0 }, - { "bias-pull-down", PIN_CONFIG_BIAS_PULL_DOWN, 0 }, - { "bias-pull-pin-default", PIN_CONFIG_BIAS_PULL_PIN_DEFAULT, 0 }, + { "bias-pull-up", PIN_CONFIG_BIAS_PULL_UP, 1 }, + { "bias-pull-down", PIN_CONFIG_BIAS_PULL_DOWN, 1 }, + { "bias-pull-pin-default", PIN_CONFIG_BIAS_PULL_PIN_DEFAULT, 1 }, { "drive-push-pull", PIN_CONFIG_DRIVE_PUSH_PULL, 0 }, { "drive-open-drain", PIN_CONFIG_DRIVE_OPEN_DRAIN, 0 }, { "drive-open-source", PIN_CONFIG_DRIVE_OPEN_SOURCE, 0 }, @@ -165,7 +165,8 @@ static struct pinconf_generic_dt_params dt_params[] = { { "input-debounce", PIN_CONFIG_INPUT_DEBOUNCE, 0 }, { "power-source", PIN_CONFIG_POWER_SOURCE, 0 }, { "slew-rate", PIN_CONFIG_SLEW_RATE, 0 }, - { "low-power-mode", PIN_CONFIG_LOW_POWER_MODE, 0 }, + { "low-power-enable", PIN_CONFIG_LOW_POWER_MODE, 1 }, + { "low-power-disable", PIN_CONFIG_LOW_POWER_MODE, 0 }, { "output-low", PIN_CONFIG_OUTPUT, 0, }, { "output-high", PIN_CONFIG_OUTPUT, 1, }, }; -- 1.7.10.4
WARNING: multiple messages have this Message-ID (diff)
From: heiko@sntech.de (Heiko Stübner) To: linux-arm-kernel@lists.infradead.org Subject: [PATCH 2/5] pinctrl: clarify some dt pinconfig options Date: Fri, 14 Jun 2013 17:42:49 +0200 [thread overview] Message-ID: <201306141742.49923.heiko@sntech.de> (raw) In-Reply-To: <201306141741.46077.heiko@sntech.de> The bias-pull-* options use values > 0 to indicate that the pull should be activated and optionally also indicate the strength of the pull. Therefore use an default value of 1 for these options. Split the low-power-mode option into low-power-enable and -disable. Update the documentation to describe the param arguments better. Wrong default options Reported-by: James Hogan <james.hogan@imgtec.com> Signed-off-by: Heiko Stuebner <heiko@sntech.de> --- .../bindings/pinctrl/pinctrl-bindings.txt | 22 +++++++++++++++++++- drivers/pinctrl/pinconf-generic.c | 9 ++++---- 2 files changed, 26 insertions(+), 5 deletions(-) diff --git a/Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt b/Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt index ef7cd57..2d730e3 100644 --- a/Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt +++ b/Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt @@ -158,9 +158,29 @@ input-schmitt - run in schmitt-trigger mode with hysteresis X input-debounce - debounce mode with debound time X power-source - select power source X slew-rate - use slew-rate X -low-power-mode - low power mode +low-power-enable - enable low power mode +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 +Arguments for parameters: + +- bias-pull-up, -down and -pin-default take as optional argument 0 to disable + the pull, on hardware supporting it the pull strength in Ohm. bias-disable + will also disable any active pull. + +- drive-strength takes as argument the target strength in mA. + +- input-schmitt takes as argument the adjustable hysteresis in a + driver-specific format + +- input-debounce takes the debounce time as argument or 0 to disable debouncing + +- power-source argument is the custom value describing the source to select + +- slew-rate takes as argument the target rate in a driver-specific format + +All parameters not listed here, do not take an argument. + 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 d3c693c..dcf0371 100644 --- a/drivers/pinctrl/pinconf-generic.c +++ b/drivers/pinctrl/pinconf-generic.c @@ -152,9 +152,9 @@ static struct pinconf_generic_dt_params dt_params[] = { { "bias-disable", PIN_CONFIG_BIAS_DISABLE, 0 }, { "bias-high-impedance", PIN_CONFIG_BIAS_HIGH_IMPEDANCE, 0 }, { "bias-bus-hold", PIN_CONFIG_BIAS_BUS_HOLD, 0 }, - { "bias-pull-up", PIN_CONFIG_BIAS_PULL_UP, 0 }, - { "bias-pull-down", PIN_CONFIG_BIAS_PULL_DOWN, 0 }, - { "bias-pull-pin-default", PIN_CONFIG_BIAS_PULL_PIN_DEFAULT, 0 }, + { "bias-pull-up", PIN_CONFIG_BIAS_PULL_UP, 1 }, + { "bias-pull-down", PIN_CONFIG_BIAS_PULL_DOWN, 1 }, + { "bias-pull-pin-default", PIN_CONFIG_BIAS_PULL_PIN_DEFAULT, 1 }, { "drive-push-pull", PIN_CONFIG_DRIVE_PUSH_PULL, 0 }, { "drive-open-drain", PIN_CONFIG_DRIVE_OPEN_DRAIN, 0 }, { "drive-open-source", PIN_CONFIG_DRIVE_OPEN_SOURCE, 0 }, @@ -165,7 +165,8 @@ static struct pinconf_generic_dt_params dt_params[] = { { "input-debounce", PIN_CONFIG_INPUT_DEBOUNCE, 0 }, { "power-source", PIN_CONFIG_POWER_SOURCE, 0 }, { "slew-rate", PIN_CONFIG_SLEW_RATE, 0 }, - { "low-power-mode", PIN_CONFIG_LOW_POWER_MODE, 0 }, + { "low-power-enable", PIN_CONFIG_LOW_POWER_MODE, 1 }, + { "low-power-disable", PIN_CONFIG_LOW_POWER_MODE, 0 }, { "output-low", PIN_CONFIG_OUTPUT, 0, }, { "output-high", PIN_CONFIG_OUTPUT, 1, }, }; -- 1.7.10.4
next prev parent reply other threads:[~2013-06-14 15:42 UTC|newest] Thread overview: 61+ messages / expand[flat|nested] mbox.gz Atom feed top 2013-06-14 15:41 [PATCH 0/5] pinctrl: fix some issues with new pinconfig dt parsing Heiko Stübner 2013-06-14 15:41 ` Heiko Stübner 2013-06-14 15:41 ` Heiko Stübner 2013-06-14 15:42 ` [PATCH 1/5] pinctrl: update the documentation for some pinconfig params Heiko Stübner 2013-06-14 15:42 ` Heiko Stübner 2013-06-14 15:42 ` Heiko Stübner 2013-06-16 10:26 ` Linus Walleij 2013-06-16 10:26 ` Linus Walleij 2013-06-16 10:26 ` Linus Walleij 2013-06-16 10:45 ` Heiko Stübner 2013-06-16 10:45 ` Heiko Stübner 2013-06-16 10:45 ` Heiko Stübner 2013-06-16 12:26 ` Linus Walleij 2013-06-16 12:26 ` Linus Walleij 2013-06-16 12:26 ` Linus Walleij 2013-06-14 15:42 ` Heiko Stübner [this message] 2013-06-14 15:42 ` [PATCH 2/5] pinctrl: clarify some dt pinconfig options Heiko Stübner 2013-06-14 15:42 ` Heiko Stübner 2013-06-16 10:28 ` Linus Walleij 2013-06-16 10:28 ` Linus Walleij 2013-06-16 10:28 ` Linus Walleij 2013-06-19 22:10 ` Stephen Warren 2013-06-19 22:10 ` Stephen Warren 2013-06-19 22:10 ` Stephen Warren 2013-06-24 9:51 ` Linus Walleij 2013-06-24 9:51 ` Linus Walleij 2013-06-14 15:43 ` [PATCH 3/5] pinctrl: handle zero found dt pinconfig properties better Heiko Stübner 2013-06-14 15:43 ` Heiko Stübner 2013-06-14 15:43 ` Heiko Stübner 2013-06-16 10:29 ` Linus Walleij 2013-06-16 10:29 ` Linus Walleij 2013-06-16 10:29 ` Linus Walleij 2013-06-14 15:43 ` [PATCH 4/5] pinctrl: dynamically alloc temp array when parsing dt pinconf options Heiko Stübner 2013-06-14 15:43 ` Heiko Stübner 2013-06-14 15:43 ` Heiko Stübner 2013-06-16 10:31 ` Linus Walleij 2013-06-16 10:31 ` Linus Walleij 2013-06-16 10:31 ` Linus Walleij 2013-06-14 15:44 ` [PATCH 5/5] pinctrl: rockchip: correctly handle arguments of " Heiko Stübner 2013-06-14 15:44 ` Heiko Stübner 2013-06-14 15:44 ` Heiko Stübner 2013-06-16 10:35 ` Linus Walleij 2013-06-16 10:35 ` Linus Walleij 2013-06-16 10:35 ` Linus Walleij 2013-06-16 11:02 ` Heiko Stübner 2013-06-16 11:02 ` Heiko Stübner 2013-06-16 11:02 ` Heiko Stübner 2013-06-16 12:35 ` Linus Walleij 2013-06-16 12:35 ` Linus Walleij 2013-06-16 12:35 ` Linus Walleij 2013-06-16 15:41 ` [PATCH v2] " Heiko Stübner 2013-06-16 15:41 ` Heiko Stübner 2013-06-16 15:41 ` Heiko Stübner 2013-06-17 15:48 ` Linus Walleij 2013-06-17 15:48 ` Linus Walleij 2013-06-17 15:48 ` Linus Walleij 2013-06-14 15:53 ` [PATCH 0/5] pinctrl: fix some issues with new pinconfig dt parsing James Hogan 2013-06-14 15:53 ` James Hogan 2013-06-14 15:53 ` James Hogan 2013-06-17 3:03 ` Laurent Pinchart 2013-06-17 3:03 ` Laurent Pinchart
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=201306141742.49923.heiko@sntech.de \ --to=heiko@sntech.de \ --cc=devicetree-discuss@lists.ozlabs.org \ --cc=grant.likely@linaro.org \ --cc=james.hogan@imgtec.com \ --cc=laurent.pinchart@ideasonboard.com \ --cc=linus.walleij@linaro.org \ --cc=linux-arm-kernel@lists.infradead.org \ --cc=linux-kernel@vger.kernel.org \ --cc=rob.herring@calxeda.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: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.