Re: [PATCH v2 3/3] scsi: ufs: mediatek: round scalable clock bounds to clk_round_rate()

From: Peter Wang

Date: Thu Nov 26 2026 - 08:04:29 EST


On Thu, 2026-11-26 at 03:10 +0000, Ilia Snezhkov via B4 Relay wrote:
> From: Ilia Snezhkov <iasnezhkov@xxxxxxxxx>
>
> ufshcd_devfreq_target() determines scale_up via an exact equality
> check
> against clki->max_freq after rounding the target frequency. When a DT
> freq-table-hz lists a nominal value that a PLL-derived clock cannot
> hit
> exactly (for example, msdcpll_d2 on MT6789 delivers 191999939 Hz for
> a
> 192000000 Hz DT maximum), clk_round_rate() produces a rate that never

Hi Ilia,

I am curious why the HW generates this value of 191999939 Hz.
Should the HW need a calibration to generate exactly 192000000 Hz?

Thanks.
Peter