[PATCH] phy: qcom-qmp-combo: correct DP register offsets

Dmitry Baryshkov dmitry.baryshkov at linaro.org
Tue Jan 24 01:19:32 PST 2023


On 24/01/2023 09:35, Johan Hovold wrote:
> On Mon, Jan 23, 2023 at 08:59:48PM +0200, Dmitry Baryshkov wrote:
>> On Mon, 23 Jan 2023 at 16:00, Johan Hovold <johan at kernel.org> wrote:
>>>
>>> On Mon, Jan 23, 2023 at 02:08:07PM +0200, Dmitry Baryshkov wrote:
>>>> Correct DP register offsets used with new DT bindings scheme. First, DP
>>>> TX registers reside in separate regions, not in the same regions as USB
>>>> TX registers do. Second, correct DP_PHY region offset to follow the
>>>> offset used for earlier generations/bindings.
>>>
>>> No, this patch is broken. SC8280XP is different, doesn't seem to have
>>> separate DP TX regions and the DP_PHY registers lies at a different
>>> offset than on previous generations.
>>>
>>> You can't just pull these numbers out of your ... ;)
>>>
>>> This is the only platform that I can test the DP part on and it is
>>> working. If that happens to be by chance, then you need to blame the
>>> commit adding support for sc8280xp (i.e. not the one that fixed the
>>> binding). And note that this was added by Bjorn who do have access to
>>> the documentation for this SoC (as well as actual hardware).
>>
>> Ack, let's wait for Bjorn to check the offsets. I find it extremely
>> suspicious that dp_txa/txb use the same region as usb txa/txb do.
> 
> Yeah, I agree, it seems odd, but then again the sc8280xp PHY is a
> different beast which also supports USB4, etc. The DP_PHY offset comes
> from the header file in the vendor tree and there are no separate DP TX
> registers there.
> 
> By the way, I forgot that Bjorn actually copy-pasted the devicetree
> nodes from an earlier platform when first adding the PHY and only later
> realised that the DP part did not work. The fix for that (e.g. to use
> the same TX registers) was never merged to mainline (instead we
> temporarily disabled the DP part) so the Fixes tag you used would have
> been correct if this turns out to be wrong.

Let's check with Bjorn. However even if the original offsets are 
correct, I think we should add dp_txa/dp_txb offsets (and make them 
equal to txa/txb in sc8280xp case). WDYT?

> 
>>>> Cc: Johan Hovold <johan+linaro at kernel.org>
>>>> Fixes: 83a0bbe39b17 ("phy: qcom-qmp-combo: add support for updated sc8280xp binding")
>>>> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov at linaro.org>
> 
> Johan

-- 
With best wishes
Dmitry




More information about the linux-phy mailing list