All of lore.kernel.org
 help / color / mirror / Atom feed
From: Krzysztof Kozlowski <krzk@kernel.org>
To: Chen-Yu Tsai <wenst@chromium.org>
Cc: Mark Brown <broonie@kernel.org>,
	Liam Girdwood <lgirdwood@gmail.com>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Matthias Brugger <matthias.bgg@gmail.com>,
	AngeloGioacchino Del Regno
	<angelogioacchino.delregno@collabora.com>,
	linux-arm-kernel@lists.infradead.org,
	linux-mediatek@lists.infradead.org, devicetree@vger.kernel.org
Subject: Re: [PATCH 2/5] regulator: dt-bindings: mt6359: Drop bogus vcn33_[12]_* split regulators
Date: Mon, 23 Mar 2026 09:31:10 +0100	[thread overview]
Message-ID: <e14ae934-e448-433f-987d-77bede5f6d07@kernel.org> (raw)
In-Reply-To: <CAGXv+5ESnhsVfu5pWf1DEt35+10ZKTgJ5G6DuJC4s6yEpRH_YQ@mail.gmail.com>

On 23/03/2026 09:26, Chen-Yu Tsai wrote:
> On Fri, Mar 20, 2026 at 5:54 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
>>
>> On Fri, Mar 20, 2026 at 03:24:35PM +0800, Chen-Yu Tsai wrote:
>>> vcn33_[12]_bt and vcn33_[12]_wifi refer to the same output. There are
>>> two enable bits in the registers so that BT and WiFi drivers can toggle
>>> them separately without any coordination. If either bit is set, then the
>>> regulator output is enabled.
>>>
>>> Unfortunately some of them are already referenced by in-tree device
>>> trees. To keep backward compatibility with them, keep the vcn33_*_bt
>>
>> So you drop "_wifi" regulators breaking the ABI, no?
> 
> Indeed it is a breakage. I kept the *_bt part to cover all in-tree
> device trees.
> 
> But the representation itself is broken, as explained in the commit
> message.
> 
> I leave it to the platform maintainers to decide whether this "breakage"
> to fix the broken representation is acceptable.
> 
> Note that there is a similar issue with the *_sshub and non _sshub
> regulators: there is only one actual output for the two. I'm still
> asking the vendor for hardware behavior specifics.
> 
>>> regulator. Also combine them for a shorten regular expression pattern.
>>
>> Instead the duplicates should be deprecated and driver should still
>> support the "_wifi" variants.
> 
> But it doesn't really work in the driver. You cannot set different
> constraints on the two, especially conflicting constraints, and expect
> them to work. And if you set the voltage on one of them, the other
> will change as well.

Of course, but now imagine a DTB with only *_wifi regulators and no *_bt.

> 
> If we want the driver to support both with _sane_ behavior, we would
> need to introduce some sort of alias lookup for both reading
> constraints and resolving supplies. The driver registers _just_ one
> regulator, and both DT nodes resolve to it.

Yes, either alias lookup or adjusting the regulator_desc before
registering them, depending on the nodes.

If I understood old code correctly, the point is that ABI allowed *_wifi
without *_bt and this would be a working setup. Now it won't work.

Best regards,
Krzysztof


  reply	other threads:[~2026-03-23  8:31 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-20  7:24 [PATCH 0/5] regulator: mt6359: cleanup and add supplies Chen-Yu Tsai
2026-03-20  7:24 ` [PATCH 1/5] regulator: dt-bindings: mt6359: Drop regulator-name pattern restrictions Chen-Yu Tsai
2026-03-20  9:32   ` Krzysztof Kozlowski
2026-03-20  7:24 ` [PATCH 2/5] regulator: dt-bindings: mt6359: Drop bogus vcn33_[12]_* split regulators Chen-Yu Tsai
2026-03-20  9:54   ` Krzysztof Kozlowski
2026-03-23  8:26     ` Chen-Yu Tsai
2026-03-23  8:31       ` Krzysztof Kozlowski [this message]
2026-03-24  3:42         ` Chen-Yu Tsai
2026-03-20  7:24 ` [PATCH 3/5] regulator: dt-bindings: mt6359: Add regulator supplies Chen-Yu Tsai
2026-03-20  9:58   ` Krzysztof Kozlowski
2026-03-20  7:24 ` [PATCH 4/5] regulator: mt6359: Drop bogus vcn33_[12]_* split regulators Chen-Yu Tsai
2026-03-20  7:24 ` [PATCH 5/5] regulator: mt6359: Add regulator supply names Chen-Yu Tsai

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=e14ae934-e448-433f-987d-77bede5f6d07@kernel.org \
    --to=krzk@kernel.org \
    --cc=angelogioacchino.delregno@collabora.com \
    --cc=broonie@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=matthias.bgg@gmail.com \
    --cc=robh@kernel.org \
    --cc=wenst@chromium.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 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.