From: Christian Marangi <ansuelsmth@gmail.com>
To: Krzysztof Kozlowski <krzk@kernel.org>
Cc: Vinod Koul <vkoul@kernel.org>,
Neil Armstrong <neil.armstrong@linaro.org>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Lorenzo Bianconi <lorenzo@kernel.org>,
linux-arm-kernel@lists.infradead.org,
linux-phy@lists.infradead.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v6 4/4] phy: airoha: Add support for Airoha AN7581 USB PHY
Date: Sat, 7 Mar 2026 11:57:40 +0100 [thread overview]
Message-ID: <69ac04a6.5d0a0220.2969f9.9d81@mx.google.com> (raw)
In-Reply-To: <52123051-0d2d-42b2-b677-99a5de0f2c4e@kernel.org>
On Sat, Mar 07, 2026 at 11:40:48AM +0100, Krzysztof Kozlowski wrote:
> On 07/03/2026 11:37, Christian Marangi wrote:
> >>> +
> >>> + if (phy_type == PHY_TYPE_USB3) {
> >>> + ret = of_property_read_u32(dev->of_node, "airoha,usb3-serdes",
> >>> + &priv->serdes_port);
> >>> + if (ret)
> >>> + return dev_err_probe(dev, ret, "missing serdes line for USB 3.0\n");
> >>> +
> >>> + priv->scu = syscon_regmap_lookup_by_compatible("airoha,en7581-scu");
> >>
> >> Nope, you need phandle to express proper device links.
> >>
> >> Don't sprinkle compatible lookups for new code which does not need to
> >> keep things backwards compatible. How do you manage device links
> >> without phandle? How do you manage device probe ordering?
> >>
> >
> > Hi,
> >
> > the phandle to SCU was present in old implementation but later dropped as it was
> > said that it wouldn't describe the HW.
>
>
> I went through v3 review and I did not find such said arguments. Can you
> point me to it?
>
>
Here was v2 [0] that was clock + USB PHY. (there were clock stuff as the SCU
implementation was different) The link wasn't added in the changelog as it's
quite different than this current series.
In patch 7 Rob pointed out that serdes-port + scu was a bit unusual.
Then the implementation changed in favor of a more simple one where it's the PHY
that configure everything and in this new version the usage of the SCU phandle
is really to just get the regmap and modify the single bit to select the PHY
path/mode for USB 3.0. (it's mainly the reason the SCU is referenced directly
with a compatible instead of a phandle, in the previous implementation we used a
function exposed by the SCU SSR, while in this it's just a regmap that can
PROBE_DEFER)
Rob suggested an additional layer (a PHY) to handle this but I don't feel it
would actually describe the HW this way as that bit doesn't modify another PHY
but it just toggle the mode to the related USB 3.0 PHY.
This is really another case of not-so-organized register mapping on the SoC.
[0] https://lore.kernel.org/all/20250320130054.4804-1-ansuelsmth@gmail.com/
> >
> > I will readd as airoha,scu. Is it ok for you?
> >
> > (I actually prefer phandle than hardcoding compatible as it makes things more
> > descriptive and prevent all kind of problem in the future, so I'm more than
> > happy than using that)
> >
>
>
> Best regards,
> Krzysztof
--
Ansuel
--
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy
next prev parent reply other threads:[~2026-03-07 10:57 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-06 19:01 [PATCH v6 0/4] airoha: an7581: USB support Christian Marangi
2026-03-06 19:01 ` [PATCH v6 1/4] dt-bindings: soc: Add bindings for Airoha SCU Serdes lines Christian Marangi
2026-03-07 10:29 ` Krzysztof Kozlowski
2026-03-06 19:01 ` [PATCH v6 2/4] dt-bindings: phy: Add documentation for Airoha AN7581 USB PHY Christian Marangi
2026-03-07 10:31 ` Krzysztof Kozlowski
2026-03-07 10:34 ` Christian Marangi
2026-03-06 19:01 ` [PATCH v6 3/4] phy: move and rename Airoha PCIe PHY driver to dedicated directory Christian Marangi
2026-03-06 19:01 ` [PATCH v6 4/4] phy: airoha: Add support for Airoha AN7581 USB PHY Christian Marangi
2026-03-07 10:32 ` Krzysztof Kozlowski
2026-03-07 10:37 ` Christian Marangi
2026-03-07 10:40 ` Krzysztof Kozlowski
2026-03-07 10:57 ` Christian Marangi [this message]
2026-03-07 16:38 ` Krzysztof Kozlowski
2026-03-07 18:47 ` Christian Marangi
2026-03-13 18:36 ` Krzysztof Kozlowski
2026-03-07 10:28 ` [PATCH v6 0/4] airoha: an7581: USB support Krzysztof Kozlowski
2026-03-07 11:00 ` Christian Marangi
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=69ac04a6.5d0a0220.2969f9.9d81@mx.google.com \
--to=ansuelsmth@gmail.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=krzk+dt@kernel.org \
--cc=krzk@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-phy@lists.infradead.org \
--cc=lorenzo@kernel.org \
--cc=neil.armstrong@linaro.org \
--cc=robh@kernel.org \
--cc=vkoul@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