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] [thread-next>] [day] [month] [year] [list]
Message-ID: <a1eaae1e-3e10-4512-bc83-ae25eacc43d6@quicinc.com>
Date: Thu, 2 Oct 2025 12:00:06 -0700
From: "Bao D. Nguyen" <quic_nguyenb@...cinc.com>
To: Peter Wang (王信友) <peter.wang@...iatek.com>,
        "avri.altman@....com" <avri.altman@....com>,
        "quic_cang@...cinc.com"
	<quic_cang@...cinc.com>,
        "quic_nitirawa@...cinc.com"
	<quic_nitirawa@...cinc.com>,
        "manivannan.sadhasivam@...aro.org"
	<manivannan.sadhasivam@...aro.org>,
        "bvanassche@....org"
	<bvanassche@....org>,
        "adrian.hunter@...el.com" <adrian.hunter@...el.com>,
        "martin.petersen@...cle.com" <martin.petersen@...cle.com>
CC: "linux-scsi@...r.kernel.org" <linux-scsi@...r.kernel.org>,
        "beanhuo@...ron.com" <beanhuo@...ron.com>,
        "alim.akhtar@...sung.com"
	<alim.akhtar@...sung.com>,
        "James.Bottomley@...senPartnership.com"
	<James.Bottomley@...senPartnership.com>,
        "linux-kernel@...r.kernel.org"
	<linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v1 2/2] scsi: ufs: core: Reduce the sleep before vcc can
 be powered on

On 10/2/2025 12:59 AM, Peter Wang (王信友) wrote:
> On Wed, 2025-10-01 at 13:57 -0700, Bao D. Nguyen wrote:
>>
>> After the ufs device vcc is powered off, all the ufs device
>> manufacturers require a minimum of 1ms of power-off time before
>> vcc can be powered on again. This requirement has been verified
>> with all the ufs device manufacturer's datasheets.
>> Improve the system resume latency by reducing the required power-off
>> time from 5ms to 2ms. The chosen 2ms should include enough
>> additional buffer time without being wasteful.
>>
>> Signed-off-by: Bao D. Nguyen <quic_nguyenb@...cinc.com>
>> ---
>>   drivers/ufs/core/ufshcd.c | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/ufs/core/ufshcd.c b/drivers/ufs/core/ufshcd.c
>> index 45e509b..83bd731 100644
>> --- a/drivers/ufs/core/ufshcd.c
>> +++ b/drivers/ufs/core/ufshcd.c
>> @@ -9741,7 +9741,7 @@ static void ufshcd_vreg_set_lpm(struct ufs_hba
>> *hba)
>>           * All UFS devices require delay after VCC power rail is
>> turned-off.
>>           */
>>          if (vcc_off && hba->vreg_info.vcc)
>> -               usleep_range(5000, 5100);
>> +               usleep_range(2000, 2100);
> 
> Hi Bao,
> 
> This delay should be compatible with legacy devices.
> The initial value was set to 5ms, does that mean there
> is a device that actually needs 5ms?

Hi Peter,
I have discussed with the major ufs vendors (Samsung, Kioxia, Micron, 
and SK Hynix) via emails. They are all in agreement that 2ms is good. I 
did check the current device's datasheets and 1ms is what their 
specifications require. I admit that I may have missed some very old ufs 
device's datasheets. However, I take the words of the ufs vendor's 
engineering teams and the current device's datasheets that the 2ms is 
good for their devices and try to improve the potentially conservative 
5ms delay parameter.

Thanks, Bao

> 
> Thanks
> Peter
> 


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ