From: David Cohen <david.a.cohen@linux.intel.com>
To: Alexandre Courbot <gnurou@gmail.com>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>,
Linus Walleij <linus.walleij@linaro.org>,
Heikki Krogerus <heikki.krogerus@linux.intel.com>,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>,
Darren Hart <dvhart@linux.intel.com>,
Arnd Bergmann <arnd@arndb.de>,
Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
Mika Westerberg <mika.westerberg@linux.intel.com>,
"linux-gpio@vger.kernel.org" <linux-gpio@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
ACPI Devel Maling List <linux-acpi@vger.kernel.org>
Subject: Re: [RFC PATCH] gpio: support for GPIO forwarding
Date: Wed, 25 Feb 2015 10:25:02 -0800 [thread overview]
Message-ID: <20150225182502.GA7586@psi-dev26.jf.intel.com> (raw)
In-Reply-To: <CAAVeFuKhD2VBf3EOCjHqJK5CLx4qC8Quire2My9nMqboZzSNZQ@mail.gmail.com>
On Wed, Feb 25, 2015 at 10:34:45AM +0900, Alexandre Courbot wrote:
> On Wed, Feb 25, 2015 at 5:34 AM, David Cohen
> <david.a.cohen@linux.intel.com> wrote:
> > Hi,
> >
> >> If we decide to go ahead with the solution proposed by this patch for
> >> practical reasons (which are good reasons indeed), I still have one
> >> problem with its current form.
> >>
> >> As the discussion highlighted, this is an ACPI problem, so I'd very
> >> much like it to be confined to the ACPI GPIO code, to be enabled only
> >> when ACPI is, and to use function names that start with acpi_gpio. The
> >> current implementation leverages platform lookup, making said lookup
> >> less efficient in the process and bringing confusion about its
> >> purpose. Although the two processes are indeed similar, they are
> >> separate things: one is a legitimate way to map GPIOs, the other is a
> >> fixup for broken firmware.
> >>
> >> I suppose we all agree this is a hackish fix, so let's confine it as
> >> much as we can.
> >
> > Are we considering MFD cases hackish as well?
> > i.e. if we have a driver that needs to register children devices and this
> > driver needs to pass GPIO to a child.
>
> In that case wouldn't the GPIO be best defined in the child node
> itself, for the child device's driver to directly probe?
In my case [1] I need 2 "virtual devices" (and more in future) to be
part of an USB OTG port control. I call it virtual because they are too
simple components connected to no bus and controlled by GPIOs:
- a fixed regulator controlled by GPIO
- a generic mux controlled by GPIO
I'd need to request official ACPI HID for them in order to make them
self-sufficient.
I can go ahead with this approach, but we have many examples of drivers
on upstream that are platform driver expecting to receive gpio via
platform data (e.g. extcon-gpio). The ACPI table of some products on
market were defined following this concept and won't change anymore.
Br, David
[1] https://lkml.org/lkml/2015/2/19/411
next prev parent reply other threads:[~2015-02-25 18:25 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-18 8:23 [RFC PATCH] gpio: support for GPIO forwarding Heikki Krogerus
2015-01-08 8:25 ` Heikki Krogerus
2015-01-15 9:21 ` Rafael J. Wysocki
2015-01-14 12:58 ` Linus Walleij
2015-01-14 16:32 ` Darren Hart
2015-01-15 9:28 ` Rafael J. Wysocki
2015-01-15 9:40 ` Heikki Krogerus
2015-01-14 16:32 ` Darren Hart
2015-01-19 5:59 ` Alexandre Courbot
2015-01-19 11:53 ` Heikki Krogerus
2015-01-20 12:16 ` Linus Walleij
2015-01-20 21:25 ` Rafael J. Wysocki
2015-01-22 2:57 ` Alexandre Courbot
2015-01-22 16:14 ` Rafael J. Wysocki
2015-01-23 11:21 ` Heikki Krogerus
2015-01-23 15:14 ` Rafael J. Wysocki
2015-01-26 13:06 ` Heikki Krogerus
2015-02-10 9:32 ` Alexandre Courbot
2015-02-10 15:10 ` Rafael J. Wysocki
2015-02-10 15:10 ` Rafael J. Wysocki
2015-02-12 12:46 ` Heikki Krogerus
2015-02-12 12:46 ` Heikki Krogerus
2015-02-24 20:34 ` David Cohen
2015-02-25 1:34 ` Alexandre Courbot
2015-02-25 18:25 ` David Cohen [this message]
2015-03-07 22:13 ` Linus Walleij
2015-01-22 8:17 ` Linus Walleij
2015-01-22 16:12 ` Rafael J. Wysocki
2015-01-30 14:48 ` Linus Walleij
2015-01-30 16:17 ` Rafael J. Wysocki
2015-02-04 9:51 ` Linus Walleij
2015-02-04 14:11 ` Heikki Krogerus
2015-02-10 9:44 ` Alexandre Courbot
2015-02-12 12:38 ` Heikki Krogerus
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=20150225182502.GA7586@psi-dev26.jf.intel.com \
--to=david.a.cohen@linux.intel.com \
--cc=andriy.shevchenko@linux.intel.com \
--cc=arnd@arndb.de \
--cc=dvhart@linux.intel.com \
--cc=gnurou@gmail.com \
--cc=heikki.krogerus@linux.intel.com \
--cc=linus.walleij@linaro.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mika.westerberg@linux.intel.com \
--cc=rafael.j.wysocki@intel.com \
--cc=rjw@rjwysocki.net \
/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.