mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Dong Aisheng <aisheng.dong@freescale.com>
To: Stephen Warren <swarren@nvidia.com>
Cc: Linus Walleij <linus.walleij@linaro.org>,
	Linus Walleij <linus.walleij@stericsson.com>,
	Dong Aisheng-B29396 <B29396@freescale.com>,
	"s.hauer@pengutronix.de" <s.hauer@pengutronix.de>,
	"dongas86@gmail.com" <dongas86@gmail.com>,
	"shawn.guo@linaro.org" <shawn.guo@linaro.org>,
	"thomas.abraham@linaro.org" <thomas.abraham@linaro.org>,
	"tony@atomide.com" <tony@atomide.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH V3 4/7] pinctrl: API changes to support multiple states per device
Date: Mon, 5 Mar 2012 16:03:02 +0800	[thread overview]
Message-ID: <20120305080301.GB21987@shlinux2.ap.freescale.net> (raw)
In-Reply-To: <1330718750-15217-5-git-send-email-swarren@nvidia.com>

On Sat, Mar 03, 2012 at 04:05:47AM +0800, Stephen Warren wrote:
> The API model is changed from:
> 
> p = pinctrl_get(dev, "state1");
> pinctrl_enable(p);
> ...
> pinctrl_disable(p);
> pinctrl_put(p);
> p = pinctrl_get(dev, "state2");
> pinctrl_enable(p);
> ...
> pinctrl_disable(p);
> pinctrl_put(p);
> 
> to this:
> 
> p = pinctrl_get(dev);
> s1 = pinctrl_lookup_state(p, "state1");
> s2 = pinctrl_lookup_state(p, "state2");
> pinctrl_select_state(p, s1);
> ...
> pinctrl_select_state(p, s2);
> ...
> pinctrl_put(p);
> 
> This allows devices to directly transition between states without
> disabling the pin controller programming and put()/get()ing the
> configuration data each time. This model will also better suit pinconf
> programming, which doesn't have a concept of "disable".
> 
> The special-case hogging feature of pin controllers is re-written to use
> the regular APIs instead of special-case code. Hence, the pinmux-hogs
> debugfs file is removed; see the top-level pinctrl-handles files for
> equivalent data.
> 
> Signed-off-by: Stephen Warren <swarren@nvidia.com>
> ---
> v3: Rebased. No logical changes.
> v2: Make use of PINCTRL_STATE_DEFAULT, split out some documentation
> cleanup into an earlier patch. Various minor fixes. Fixes due to
> rebasing on updated earlier patches. Remove usecount field from struct
> pinctrl; allow only one concurrent pinctrl_get() per device.
> ---
Acked-by: Dong Aisheng <dong.aisheng@linaro.org>

I already acked it in v2, since no changes, ack it again. :-)

Regards
Dong Aisheng


  reply	other threads:[~2012-03-05  7:58 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-02 20:05 [PATCH V3 0/7] pinctrl: API rework, pinconfig in mapping table, Stephen Warren
2012-03-02 20:05 ` [PATCH V3 1/7] pinctrl: Fix and simplify locking Stephen Warren
2012-03-02 20:05 ` [PATCH V3 2/7] pinctrl: Refactor struct pinctrl handling in core.c vs pinmux.c Stephen Warren
2012-03-02 20:05 ` [PATCH V3 3/7] pinctrl: Add usecount to pins for muxing Stephen Warren
2012-03-02 20:05 ` [PATCH V3 4/7] pinctrl: API changes to support multiple states per device Stephen Warren
2012-03-05  8:03   ` Dong Aisheng [this message]
2012-03-02 20:05 ` [PATCH V3 5/7] pinctrl: Enhance mapping table to support pin config operations Stephen Warren
2012-03-02 20:05 ` [PATCH V3 6/7] pinctrl: Show selected function and group in pinmux-pins debugfs Stephen Warren
2012-03-02 20:05 ` [PATCH V3 7/7] pinctrl: fix case of Tegra30's foo_groups[] arrays Stephen Warren
2012-03-05 10:34   ` Linus Walleij
2012-03-05 18:15     ` Stephen Warren
2012-03-05 10:39 ` [PATCH V3 0/7] pinctrl: API rework, pinconfig in mapping table, Linus Walleij
2012-03-05 18:25   ` Stephen Warren

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=20120305080301.GB21987@shlinux2.ap.freescale.net \
    --to=aisheng.dong@freescale.com \
    --cc=B29396@freescale.com \
    --cc=dongas86@gmail.com \
    --cc=linus.walleij@linaro.org \
    --cc=linus.walleij@stericsson.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=s.hauer@pengutronix.de \
    --cc=shawn.guo@linaro.org \
    --cc=swarren@nvidia.com \
    --cc=thomas.abraham@linaro.org \
    --cc=tony@atomide.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®