From: Thierry Reding <thierry.reding@gmail.com>
To: Linus Walleij <linus.walleij@linaro.org>
Cc: Bartosz Golaszewski <bgolaszewski@baylibre.com>,
Jon Hunter <jonathanh@nvidia.com>,
Vidya Sagar <vidyas@nvidia.com>,
"open list:GPIO SUBSYSTEM" <linux-gpio@vger.kernel.org>,
linux-tegra@vger.kernel.org
Subject: Re: [PATCH 1/9] gpio: Support GPIO controllers without pin-ranges
Date: Fri, 27 Mar 2020 13:13:51 +0100 [thread overview]
Message-ID: <20200327121351.GA2229783@ulmo> (raw)
In-Reply-To: <CACRpkda5M4NPvMBBLg+_2BJw7ZmryrgN72JZL_XAFQ137s0OLA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1009 bytes --]
On Fri, Mar 27, 2020 at 11:37:07AM +0100, Linus Walleij wrote:
> On Thu, Mar 19, 2020 at 1:27 PM Thierry Reding <thierry.reding@gmail.com> wrote:
>
> > From: Thierry Reding <treding@nvidia.com>
> >
> > Wake gpiochip_generic_request() call into the pinctrl helpers only if a
> > GPIO controller had any pin-ranges assigned to it. This allows a driver
> > to unconditionally use this helper if it supports multiple devices of
> > which only a subset have pin-ranges assigned to them.
> >
> > Signed-off-by: Thierry Reding <treding@nvidia.com>
>
> Patch applied.
>
> We have some drivers like this:
> drivers/gpio/gpio-pl061.c:
>
> if (of_property_read_bool(dev->of_node, "gpio-ranges")) {
> pl061->gc.request = gpiochip_generic_request;
> pl061->gc.free = gpiochip_generic_free;
> }
>
> Should we just make a patch assigning these callbacks
> unconditionally as a follow-up?
Yeah, that's a good idea. I'll look into it.
Thierry
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
WARNING: multiple messages have this Message-ID (diff)
From: Thierry Reding <thierry.reding-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: Linus Walleij <linus.walleij-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
Cc: Bartosz Golaszewski
<bgolaszewski-rdvid1DuHRBWk0Htik3J/w@public.gmane.org>,
Jon Hunter <jonathanh-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>,
Vidya Sagar <vidyas-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>,
"open list:GPIO SUBSYSTEM"
<linux-gpio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH 1/9] gpio: Support GPIO controllers without pin-ranges
Date: Fri, 27 Mar 2020 13:13:51 +0100 [thread overview]
Message-ID: <20200327121351.GA2229783@ulmo> (raw)
In-Reply-To: <CACRpkda5M4NPvMBBLg+_2BJw7ZmryrgN72JZL_XAFQ137s0OLA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
[-- Attachment #1: Type: text/plain, Size: 1097 bytes --]
On Fri, Mar 27, 2020 at 11:37:07AM +0100, Linus Walleij wrote:
> On Thu, Mar 19, 2020 at 1:27 PM Thierry Reding <thierry.reding-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
>
> > From: Thierry Reding <treding-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
> >
> > Wake gpiochip_generic_request() call into the pinctrl helpers only if a
> > GPIO controller had any pin-ranges assigned to it. This allows a driver
> > to unconditionally use this helper if it supports multiple devices of
> > which only a subset have pin-ranges assigned to them.
> >
> > Signed-off-by: Thierry Reding <treding-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
>
> Patch applied.
>
> We have some drivers like this:
> drivers/gpio/gpio-pl061.c:
>
> if (of_property_read_bool(dev->of_node, "gpio-ranges")) {
> pl061->gc.request = gpiochip_generic_request;
> pl061->gc.free = gpiochip_generic_free;
> }
>
> Should we just make a patch assigning these callbacks
> unconditionally as a follow-up?
Yeah, that's a good idea. I'll look into it.
Thierry
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2020-03-27 12:13 UTC|newest]
Thread overview: 63+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-19 12:27 [PATCH 0/9] pinctrl: tegra: Support SFIO/GPIO programming Thierry Reding
2020-03-19 12:27 ` Thierry Reding
2020-03-19 12:27 ` [PATCH 1/9] gpio: Support GPIO controllers without pin-ranges Thierry Reding
2020-03-19 12:27 ` Thierry Reding
2020-03-19 17:05 ` Vidya Sagar
2020-03-19 17:05 ` Vidya Sagar
2020-03-21 12:34 ` kbuild test robot
2020-03-27 10:37 ` Linus Walleij
2020-03-27 10:37 ` Linus Walleij
2020-03-27 12:13 ` Thierry Reding [this message]
2020-03-27 12:13 ` Thierry Reding
2020-03-19 12:27 ` [PATCH 2/9] gpio: tegra186: Add support for pin ranges Thierry Reding
2020-03-19 17:05 ` Vidya Sagar
2020-03-19 17:05 ` Vidya Sagar
2020-03-27 10:39 ` Linus Walleij
2020-03-27 10:39 ` Linus Walleij
2020-03-31 20:53 ` Thierry Reding
2020-03-19 12:27 ` [PATCH 3/9] gpio: tegra186: Add Tegra194 pin ranges for GG.0 and GG.1 Thierry Reding
2020-03-19 17:06 ` Vidya Sagar
2020-03-19 17:06 ` Vidya Sagar
2020-03-27 10:39 ` Linus Walleij
2020-03-27 10:39 ` Linus Walleij
2020-03-19 12:27 ` [PATCH 4/9] pinctrl: tegra: Fix whitespace issues for improved readability Thierry Reding
2020-03-19 12:27 ` Thierry Reding
2020-03-19 17:06 ` Vidya Sagar
2020-03-19 17:06 ` Vidya Sagar
2020-03-27 10:40 ` Linus Walleij
2020-03-27 10:40 ` Linus Walleij
2020-03-19 12:27 ` [PATCH 5/9] pinctrl: tegra: Fix "Scmitt" -> "Schmitt" typo Thierry Reding
2020-03-19 17:07 ` Vidya Sagar
2020-03-19 17:07 ` Vidya Sagar
2020-03-27 10:42 ` Linus Walleij
2020-03-27 10:42 ` Linus Walleij
2020-03-19 12:27 ` [PATCH 6/9] pinctrl: tegra: Pass struct tegra_pmx for pin range check Thierry Reding
2020-03-19 12:27 ` Thierry Reding
2020-03-19 17:07 ` Vidya Sagar
2020-03-19 17:07 ` Vidya Sagar
2020-03-27 10:43 ` Linus Walleij
2020-03-27 10:43 ` Linus Walleij
2020-03-19 12:27 ` [PATCH 7/9] pinctrl: tegra: Do not add default pin range on Tegra194 Thierry Reding
2020-03-19 12:27 ` Thierry Reding
2020-03-19 17:08 ` Vidya Sagar
2020-03-19 17:08 ` Vidya Sagar
2020-03-27 10:44 ` Linus Walleij
2020-03-27 10:44 ` Linus Walleij
2020-03-19 12:27 ` [PATCH 8/9] pinctrl: tegra: Renumber the GG.0 and GG.1 pins Thierry Reding
2020-03-19 12:27 ` Thierry Reding
2020-03-19 17:08 ` Vidya Sagar
2020-03-19 17:08 ` Vidya Sagar
2020-03-27 10:45 ` Linus Walleij
2020-03-27 10:45 ` Linus Walleij
2020-03-19 12:27 ` [PATCH 9/9] pinctrl: tegra: Add SFIO/GPIO programming on Tegra194 Thierry Reding
2020-03-19 12:27 ` Thierry Reding
2020-03-19 17:08 ` Vidya Sagar
2020-03-19 17:08 ` Vidya Sagar
2020-03-27 10:46 ` Linus Walleij
2020-03-27 10:46 ` Linus Walleij
2020-03-19 17:04 ` [PATCH 0/9] pinctrl: tegra: Support SFIO/GPIO programming Vidya Sagar
2020-03-19 17:04 ` Vidya Sagar
2020-03-20 19:37 ` Linus Walleij
2020-03-20 19:37 ` Linus Walleij
2020-03-23 13:16 ` Thierry Reding
2020-03-23 13:16 ` Thierry Reding
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=20200327121351.GA2229783@ulmo \
--to=thierry.reding@gmail.com \
--cc=bgolaszewski@baylibre.com \
--cc=jonathanh@nvidia.com \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-tegra@vger.kernel.org \
--cc=vidyas@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.