linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kent Gibson <warthog618@gmail.com>
To: "Westermann, Oliver" <Oliver.Westermann@cognex.com>
Cc: Bartosz Golaszewski <brgl@bgdev.pl>,
	"ada@thorsis.com" <ada@thorsis.com>,
	"linux-gpio@vger.kernel.org" <linux-gpio@vger.kernel.org>
Subject: Re: Re: Assign line names at runtime
Date: Fri, 19 Jan 2024 07:48:30 +0800	[thread overview]
Message-ID: <20240118234830.GA11295@rigel> (raw)
In-Reply-To: <PH0PR06MB8334079C458EF28FE056CD75866F2@PH0PR06MB8334.namprd06.prod.outlook.com>

On Fri, Jan 12, 2024 at 01:16:29PM +0000, Westermann, Oliver wrote:
>
>
> On Fri, Jan 12, 2024 at 1:31 AM Kent Gibson wrote:
> > So I'm at the point that I think we could do it, one way or another, but
> > much less certain if we should.
> > I would not consider it if there was an alternative.
>
> I played around a bit this morning and I have a (probably hacky but) working
> prototype which adds a GPIO_V2_SET_LINEINFO_IOCTL and currently only allows to
> override a line name. I played around a bit and tried to break something, but
> currently, it seems to work. But I'm also open for any alternative, so maybe
> with some extra info, somebody has better ideas:
>
> The hardware variants I'm dealing with could be considered accessories:
> Extension of a base in different kind and revisions. As those, they are mostly
> not boot critical - I can defer probing. That would also allow me to defer
> probing up until manual probing from userspace, eg by a udev rule collecting
> more data and providing that to the driver once all data is present.
>
> Could e.g. an extension of the modprobe params for i2c gpiochip drivers allow to
> provide not only bus and address, but also a list of pin names? Ideally
> implemented on the gpiochip / i2c gpio level so this applies to all gpio drivers?
>
> (new attempt at manual formatting, sorry)
>

Sorry for the belated reply, but just to clarify where I am with this:

This looks like an init-time problem, more so than a runtime, so you
should pursue the init-time solutions and exhaust your options there
before looking to solve it via the GPIO uAPI.

Cheers,
Kent.



      reply	other threads:[~2024-01-18 23:48 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-11 16:52 Assign line names at runtime Westermann, Oliver
2024-01-12  0:35 ` Kent Gibson
2024-01-12 11:26   ` Bartosz Golaszewski
2024-01-12 12:31     ` Kent Gibson
2024-01-12 13:16       ` Westermann, Oliver
2024-01-18 23:48         ` Kent Gibson [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=20240118234830.GA11295@rigel \
    --to=warthog618@gmail.com \
    --cc=Oliver.Westermann@cognex.com \
    --cc=ada@thorsis.com \
    --cc=brgl@bgdev.pl \
    --cc=linux-gpio@vger.kernel.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).