[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <D9I8H4AII5EG.3QKI8U79KC8SO@fairphone.com>
Date: Mon, 28 Apr 2025 13:26:05 +0200
From: "Luca Weiss" <luca.weiss@...rphone.com>
To: "Ziqi Chen" <quic_ziqichen@...cinc.com>, <quic_cang@...cinc.com>,
<bvanassche@....org>, <mani@...nel.org>, <beanhuo@...ron.com>,
<avri.altman@....com>, <junwoo80.lee@...sung.com>,
<martin.petersen@...cle.com>, <quic_nguyenb@...cinc.com>,
<quic_nitirawa@...cinc.com>, <peter.wang@...iatek.com>,
<quic_rampraka@...cinc.com>
Cc: <linux-arm-msm@...r.kernel.org>, <linux-scsi@...r.kernel.org>, "Neil
Armstrong" <neil.armstrong@...aro.org>, "Matthias Brugger"
<matthias.bgg@...il.com>, "AngeloGioacchino Del Regno"
<angelogioacchino.delregno@...labora.com>, "open list:ARM/Mediatek SoC
support:Keyword:mediatek" <linux-kernel@...r.kernel.org>, "moderated
list:ARM/Mediatek SoC support:Keyword:mediatek"
<linux-arm-kernel@...ts.infradead.org>, "moderated list:ARM/Mediatek SoC
support:Keyword:mediatek" <linux-mediatek@...ts.infradead.org>
Subject: Re: [PATCH v5 0/8] Support Multi-frequency scale for UFS
Hi Ziqi,
On Mon Apr 28, 2025 at 10:06 AM CEST, Ziqi Chen wrote:
> Hi Luca,
>
> We made changes to fix this special platform issue and verified it can
> fix this issue.
> Could you help double check if attached 3 patched can fix it from you side?
> If it is OK from you side as well, we will submit the final patches to
> upstream
With these 3 patches applied the errors are gone and I don't see any
UFS-related warnings/errors in dmesg anymore.
Let me know if I should check on anything else. Thanks for the quick
fix!
Regards
Luca
>
> Thanks a lot~
>
> BRs
> Ziqi
>
> On 4/27/2025 4:14 PM, Ziqi Chen wrote:
>> Hi Luca,
>>
>> Thanks for your report.
>> Really, 6350 is a special platform that the UFS_PHY_AXI_CLK doesn't
>> match to the UFS_PHY_UNIPRO_CORE_CLK. We already found out the root
>> cause and discussing the fix. We will submit change to fix this corner
>> case.
>>
>> BRs
>> Ziqi
>>
>> On 4/26/2025 3:48 AM, Luca Weiss wrote:
>>> Hi Ziqi,
>>>
>>> On Thu Feb 13, 2025 at 9:00 AM CET, Ziqi Chen wrote:
>>>> With OPP V2 enabled, devfreq can scale clocks amongst multiple frequency
>>>> plans. However, the gear speed is only toggled between min and max
>>>> during
>>>> clock scaling. Enable multi-level gear scaling by mapping clock
>>>> frequencies
>>>> to gear speeds, so that when devfreq scales clock frequencies we can put
>>>> the UFS link at the appropraite gear speeds accordingly.
>>>
>>> I believe this series is causing issues on SM6350:
>>>
>>> [ 0.859449] ufshcd-qcom 1d84000.ufshc: ufs_qcom_freq_to_gear_speed:
>>> Unsupported clock freq : 200000000
>>> [ 0.886668] ufshcd-qcom 1d84000.ufshc: UNIPRO clk freq 200 MHz not
>>> supported
>>> [ 0.903791] devfreq 1d84000.ufshc: dvfs failed with (-22) error
>>>
>>> That's with this patch, I actually haven't tried without on v6.15-rc3
>>> https://lore.kernel.org/all/20250314-sm6350-ufs-things-
>>> v1-2-3600362cc52c@...rphone.com/
>>>
>>> I believe the issue appears because core clk and unipro clk rates don't
>>> match on this platform, so this 200 MHz for GCC_UFS_PHY_AXI_CLK is not a
>>> valid unipro clock rate, but for GCC_UFS_PHY_UNIPRO_CORE_CLK it's
>>> specified to 150 MHz in the opp table.
>>>
>>> Regards
>>> Luca
>>>
>>>>
>>>> This series has been tested on below platforms -
>>>> sm8550 mtp + UFS3.1
>>>> SM8650 MTP + UFS3.1
>>>> SM8750 MTP + UFS4.0
>>
Powered by blists - more mailing lists