From: Johan Hovold <johan-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
To: Russell King - ARM Linux <linux-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org>
Cc: Johan Hovold <johan-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
Martin Fuzzey <mfuzzey-mB3Nsq4MPf1BDgjK7y7TUQ@public.gmane.org>,
devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
Alexandre Courbot
<gnurou-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
Linus Walleij
<linus.walleij-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
linux-gpio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
Rob Herring <robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
Subject: Re: [PATCH 0/2] gpio: Allow userspace export from DT
Date: Fri, 8 May 2015 12:04:15 +0200 [thread overview]
Message-ID: <20150508100415.GE1942@localhost> (raw)
In-Reply-To: <20150507122840.GB2067-l+eeeJia6m9vn6HldHNs0ANdhmdF6hFW@public.gmane.org>
On Thu, May 07, 2015 at 01:28:40PM +0100, Russell King - ARM Linux wrote:
> On Wed, May 06, 2015 at 03:25:20PM +0200, Johan Hovold wrote:
> > On Wed, May 06, 2015 at 01:57:08PM +0100, Russell King - ARM Linux wrote:
> > > There is *no* "firmware" on these devices. The only thing you have is a
> > > boot loader and a DT blob, and people will hate you if you tell them that
> > > they have to change the DT blob and then reboot their systems to change
> > > the functionality of a GPIO pin.
> > >
> > > It's also entirely reasonable to assume that people are going to want to
> > > change the configuration at runtime, given their diverse range of
> > > applications.
> >
> > DT can be changed at run-time using overlays.
>
> Yes, I'm aware of that, but that code is really not nice. There is no
> notification system to drivers that something has changed, and with a
> GPIO driver, you really don't want the driver to be unbound and
> re-bound just because something changed. That has the very real
> possibility to disrupt users of other GPIOs.
Yes, you'd need to configure your gpio chip before you start using it.
And for your RPi use case, things need not change much if the default
mode if undefined, or the default DT, continue to allow for full
flexibility.
But I imagine that even for such use cases some people will want to
configure pin directionality and default modes in DT (blob or overlay)
to limit potential damage from bugs in userspace applications.
And everyone should benefit from persistent, predictable pin names.
> > You also cut out the part in my reply about continuing to allow
> > unrestricted access for such cases. That could still continue to be the
> > default (e.g. when there are no pin function names defined in DT).
>
> Yes, that's standard Internet email etiquette - cut everything from
> the message you're replying to which is not part of the context of the
> immediate reply. I'd include a URL to that, but unfortunately google
> seems broken (it's inserting a refresh into the results page which causes
> elinks to continually refetch the same page, eventually triggering a
> violation of googles terms of use... yea, quite funny that google is
> instructing browsers to violate their own terms of use.)
Yes, but in this case you argued using an example that I had already
discussed in the part of the email that you left out (i.e. how to not
break userspace by continuing to allow full flexibility if desired).
Johan
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
prev parent reply other threads:[~2015-05-08 10:04 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-13 11:05 [PATCH 0/2] gpio: Allow userspace export from DT Martin Fuzzey
2015-04-13 11:05 ` [PATCH 1/2] Doc: DT: Add binding document for GPIO exporter Martin Fuzzey
2015-04-13 11:05 ` [PATCH 2/2] gpio: add driver to export DT configured GPIOs to userspace Martin Fuzzey
2015-04-15 13:19 ` [PATCH 0/2] gpio: Allow userspace export from DT Rob Herring
[not found] ` <CAL_JsqJorndYh4ROdKbJfpG1KY=Xosjc6BMFYRPrb+BsauFsnQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-04-28 12:56 ` Linus Walleij
2015-05-04 8:49 ` Johan Hovold
2015-05-06 7:22 ` Linus Walleij
2015-05-06 13:06 ` Johan Hovold
2015-05-06 17:56 ` Fuzzey, Martin
2015-05-08 9:31 ` Johan Hovold
2015-05-06 11:24 ` Russell King - ARM Linux
2015-05-06 12:43 ` Johan Hovold
2015-05-06 12:57 ` Russell King - ARM Linux
[not found] ` <20150506125707.GV2067-l+eeeJia6m9vn6HldHNs0ANdhmdF6hFW@public.gmane.org>
2015-05-06 13:25 ` Johan Hovold
2015-05-07 5:38 ` Jiří Prchal
2015-05-07 12:28 ` Russell King - ARM Linux
[not found] ` <20150507122840.GB2067-l+eeeJia6m9vn6HldHNs0ANdhmdF6hFW@public.gmane.org>
2015-05-08 10:04 ` Johan Hovold [this message]
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=20150508100415.GE1942@localhost \
--to=johan-dgejt+ai2ygdnm+yrofe0a@public.gmane.org \
--cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=gnurou-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=linus.walleij-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
--cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
--cc=linux-gpio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org \
--cc=mfuzzey-mB3Nsq4MPf1BDgjK7y7TUQ@public.gmane.org \
--cc=robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
/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;
as well as URLs for NNTP newsgroup(s).