linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jonas Jelonek <jelonek.jonas@gmail.com>
To: Rob Herring <robh@kernel.org>
Cc: Linus Walleij <linus.walleij@linaro.org>,
	Bartosz Golaszewski <brgl@bgdev.pl>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>, Peter Rosin <peda@axentia.se>,
	Geert Uytterhoeven <geert+renesas@glider.be>,
	linux-gpio@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	Thomas Richard <thomas.richard@bootlin.com>,
	Conor Dooley <conor.dooley@microchip.com>
Subject: Re: [PATCH v6 1/2] dt-bindings: gpio: add gpio-line-mux controller
Date: Tue, 11 Nov 2025 14:28:16 +0100	[thread overview]
Message-ID: <0c77dc63-7e85-4085-b48d-1885aa52bdd9@gmail.com> (raw)
In-Reply-To: <20251111125716.GA2560355-robh@kernel.org>

Hi Rob,

On 11.11.25 13:57, Rob Herring wrote:
> On Tue, Nov 11, 2025 at 09:27:03AM +0000, Jonas Jelonek wrote:
>> +    maxItems: 1
>> +    description:
>> +      Phandle to the multiplexer to control access to the GPIOs.
>> +
>> +  ngpios: false
> No need for this.
(...)
>> +        gpio-line-names = "SFP1_LOS", "SFP1_MOD_ABS", "SFP1_TX_FAULT";
>> +        gpio-line-mux-states = <0>, <1>, <3>;
> gpio-line-names is defined to have an entry for all lines. So 
> gpio-line-mux-states is not necessary. You can just do:
>
> gpio-line-names = "SFP1_LOS", "SFP1_MOD_ABS", "", "SFP1_TX_FAULT";

Not sure if I'm getting this wrong, but this ties the GPIO line index to the
multiplexer state. Is that still the correct way if my multiplexer needs
states '15', '17, '18'? Then I would need something like this:

gpio-line-names = "", "", "", "", "", "", "", "", "", "", "", "", "", "", "A", "", "B", "C"; 

And it would cause the virtual GPIO controller to provide more GPIO lines than
desired/expected/needed.

> Rob

Best,
Jonas

  reply	other threads:[~2025-11-11 13:28 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-11  9:27 [PATCH v6 0/2] add gpio-line-mux Jonas Jelonek
2025-11-11  9:27 ` [PATCH v6 1/2] dt-bindings: gpio: add gpio-line-mux controller Jonas Jelonek
2025-11-11 12:57   ` Rob Herring
2025-11-11 13:28     ` Jonas Jelonek [this message]
2025-11-11  9:27 ` [PATCH v6 2/2] gpio: add gpio-line-mux driver Jonas Jelonek

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=0c77dc63-7e85-4085-b48d-1885aa52bdd9@gmail.com \
    --to=jelonek.jonas@gmail.com \
    --cc=brgl@bgdev.pl \
    --cc=conor+dt@kernel.org \
    --cc=conor.dooley@microchip.com \
    --cc=devicetree@vger.kernel.org \
    --cc=geert+renesas@glider.be \
    --cc=krzk+dt@kernel.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=peda@axentia.se \
    --cc=robh@kernel.org \
    --cc=thomas.richard@bootlin.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 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).