lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <6e088a4a-2665-472a-ac44-a645d17b2e99@acm.org>
Date: Wed, 18 Jun 2025 08:41:18 -0700
From: Bart Van Assche <bvanassche@....org>
To: Anvith Dosapati <anvithdosapati@...gle.com>,
 Alim Akhtar <alim.akhtar@...sung.com>, Avri Altman <avri.altman@....com>
Cc: Manivannan Sadhasivam <mani@...nel.org>,
 Subhash Jadavani <subhashj@...eaurora.org>, linux-scsi@...r.kernel.org,
 linux-kernel@...r.kernel.org, manugautam@...gle.com,
 vamshigajjela@...gle.com, stable@...r.kernel.org
Subject: Re: [PATCH v2] scsi: ufs: core: Fix clk scaling to be conditional in
 reset and restore

On 6/16/25 1:57 AM, Anvith Dosapati wrote:
> From: anvithdosapati <anvithdosapati@...gle.com>
> 
> In ufshcd_host_reset_and_restore, scale up clocks only when clock
> scaling is supported. Without this change cpu latency is voted for 0
> (ufshcd_pm_qos_update) during resume unconditionally.
> 
> Signed-off-by: anvithdosapati <anvithdosapati@...gle.com>
> Fixes: a3cd5ec55f6c7 ("scsi: ufs: add load based scaling of UFS gear")
> Cc: stable@...r.kernel.org
> ---
> v2:
> - Update commit message
> - Add Fixes and Cc stable
> 
>   drivers/ufs/core/ufshcd.c | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/ufs/core/ufshcd.c b/drivers/ufs/core/ufshcd.c
> index 4410e7d93b7d..fac381ea2b3a 100644
> --- a/drivers/ufs/core/ufshcd.c
> +++ b/drivers/ufs/core/ufshcd.c
> @@ -7802,7 +7802,8 @@ static int ufshcd_host_reset_and_restore(struct ufs_hba *hba)
>   	hba->silence_err_logs = false;
>   
>   	/* scale up clocks to max frequency before full reinitialization */
> -	ufshcd_scale_clks(hba, ULONG_MAX, true);
> +	if (ufshcd_is_clkscaling_supported(hba))
> +		ufshcd_scale_clks(hba, ULONG_MAX, true);
>   
>   	err = ufshcd_hba_enable(hba);
>   

Reviewed-by: Bart Van Assche <bvanassche@....org>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ