All of lore.kernel.org
 help / color / mirror / Atom feed
From: Barry Song <21cnbao@gmail.com>
To: Linus Walleij <linus.walleij@linaro.org>
Cc: Linus Walleij <linus.walleij@stericsson.com>,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	Grant Likely <grant.likely@secretlab.ca>,
	Stephen Warren <swarren@nvidia.com>,
	Russell King <linux@arm.linux.org.uk>,
	Joe Perches <joe@perches.com>,
	Linaro Dev <linaro-dev@lists.linaro.org>,
	Lee Jones <lee.jones@linaro.org>
Subject: Re: [PATCH 0/4 v4] pin controller subsystem v4
Date: Fri, 26 Aug 2011 09:58:39 +0800	[thread overview]
Message-ID: <CAGsJ_4yEXEajH1JyNjnYE0hg13Fgd7bdiMNFs2fp6Ou=h_9N9g@mail.gmail.com> (raw)
In-Reply-To: <CACRpkdb4-0TfO-viUoZyW3VoLnVuo2ztHTX=8Hef3_RYWB52vg@mail.gmail.com>

2011/8/22 Linus Walleij <linus.walleij@linaro.org>:
> On Sun, Aug 21, 2011 at 4:42 PM, Barry Song <21cnbao@gmail.com> wrote:
>
>> it seems there is not an actual example that gpio requests pin from
>> pinctrl yet. i might give one on SiRFprimaII.
>
> No good example yet, no.
>
> The reason is that for the U300 that I use as guinea pig, the
> GPIO driver is tangled up in discussions about how to handle
> the special control mechanics like requesting muxing and
> biasing pins. Right now it seems easier to rewrite all that
> to use the new pinctrl subsystem rather than actually trying
> to work it into the GPIO subsystem first and refactor from
> there, and that needs quite a bit of upfront work...

Do you want the pinmux_request_gpio called by the gpiolib driver or by
every device driver who uses this gpio?
Do you think the following make sense in gpiolib driver?
static int xxx_gpio_request(struct gpio_chip *chip, unsigned offset)
{
        int ret = 0;

        ret = pinmux_request_gpio(chip->base + offset);
        if (ret)
                goto out;
        .....
out:
        return ret;
}


>
> Linus Walleij
>

Thanks
Barry

WARNING: multiple messages have this Message-ID (diff)
From: 21cnbao@gmail.com (Barry Song)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 0/4 v4] pin controller subsystem v4
Date: Fri, 26 Aug 2011 09:58:39 +0800	[thread overview]
Message-ID: <CAGsJ_4yEXEajH1JyNjnYE0hg13Fgd7bdiMNFs2fp6Ou=h_9N9g@mail.gmail.com> (raw)
In-Reply-To: <CACRpkdb4-0TfO-viUoZyW3VoLnVuo2ztHTX=8Hef3_RYWB52vg@mail.gmail.com>

2011/8/22 Linus Walleij <linus.walleij@linaro.org>:
> On Sun, Aug 21, 2011 at 4:42 PM, Barry Song <21cnbao@gmail.com> wrote:
>
>> it seems there is not an actual example that gpio requests pin from
>> pinctrl yet. i might give one on SiRFprimaII.
>
> No good example yet, no.
>
> The reason is that for the U300 that I use as guinea pig, the
> GPIO driver is tangled up in discussions about how to handle
> the special control mechanics like requesting muxing and
> biasing pins. Right now it seems easier to rewrite all that
> to use the new pinctrl subsystem rather than actually trying
> to work it into the GPIO subsystem first and refactor from
> there, and that needs quite a bit of upfront work...

Do you want the pinmux_request_gpio called by the gpiolib driver or by
every device driver who uses this gpio?
Do you think the following make sense in gpiolib driver?
static int xxx_gpio_request(struct gpio_chip *chip, unsigned offset)
{
        int ret = 0;

        ret = pinmux_request_gpio(chip->base + offset);
        if (ret)
                goto out;
        .....
out:
        return ret;
}


>
> Linus Walleij
>

Thanks
Barry

  reply	other threads:[~2011-08-26  1:59 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-19  9:53 [PATCH 0/4 v4] pin controller subsystem v4 Linus Walleij
2011-08-19  9:53 ` Linus Walleij
2011-08-21 14:42 ` Barry Song
2011-08-21 14:42   ` Barry Song
2011-08-22 12:28   ` Linus Walleij
2011-08-22 12:28     ` Linus Walleij
2011-08-26  1:58     ` Barry Song [this message]
2011-08-26  1:58       ` Barry Song
2011-08-26  7:57       ` Linus Walleij
2011-08-26  7:57         ` Linus Walleij
2011-08-26 17:12       ` Stephen Warren
2011-08-26 17:12         ` Stephen Warren
2011-08-29  8:33         ` Linus Walleij
2011-08-29  8:33           ` 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='CAGsJ_4yEXEajH1JyNjnYE0hg13Fgd7bdiMNFs2fp6Ou=h_9N9g@mail.gmail.com' \
    --to=21cnbao@gmail.com \
    --cc=grant.likely@secretlab.ca \
    --cc=joe@perches.com \
    --cc=lee.jones@linaro.org \
    --cc=linaro-dev@lists.linaro.org \
    --cc=linus.walleij@linaro.org \
    --cc=linus.walleij@stericsson.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    --cc=swarren@nvidia.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 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.