Re: [PATCH 09/13] dt-bindings: phy: Add documentation for Airoha AN7581 USB PHY

Krzysztof Kozlowski
2025-03-16T17:01:14Z

On 11/03/2025 19:51, Christian Marangi wrote:
>>
>>> + $ref: /schemas/types.yaml#/definitions/uint32
>>> + enum: [0, 1]
>>
>> I don't understand why do you need index property here (which are
>> usually not allowed).
>>
>
> Eh... As said in the description this is really to differentiate the 2
> different physical port...
>
> Each port have a dedicated oscillator for calibration and these
> calibration are identified by an offset (all placed one after another in
> a separate register space).

So different oscillators? Then describe the oscillator and its differences.

Different programing model? Different compatible.

Other difference? Depending what is the difference.

But there is no such thing as "different port ID" based on your
description above. You just claimed that they are different, but you do
not put that difference to hardware description. Instead you encode that
difference in the drivers and it should be opposite. The DTS, so the
hardware description, should tell you the difference. And I am sorry,
but in 99% of cases "I am the first phy" and "I am the second" is not
the actual difference we are interested in.

>
> Oscillator 0 for physical port 0
> Oscillator 1 for physcial port 1
>
> And model this is a bit problematic without an additional property, any
> hint for this?
>
Best regards,
Krzysztof