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]
Date:   Fri, 15 Nov 2019 14:35:28 +0800
From:   Stanley Chu <stanley.chu@...iatek.com>
To:     Can Guo <cang@...eaurora.org>
CC:     <asutoshd@...eaurora.org>, <nguyenb@...eaurora.org>,
        <rnayak@...eaurora.org>, <linux-scsi@...r.kernel.org>,
        <kernel-team@...roid.com>, <saravanak@...gle.com>,
        <salyzyn@...gle.com>, Alim Akhtar <alim.akhtar@...sung.com>,
        Avri Altman <avri.altman@....com>,
        Pedro Sousa <pedrom.sousa@...opsys.com>,
        "James E.J. Bottomley" <jejb@...ux.ibm.com>,
        "Martin K. Petersen" <martin.petersen@...cle.com>,
        Bean Huo <beanhuo@...ron.com>,
        Tomas Winkler <tomas.winkler@...el.com>,
        Venkat Gopalakrishnan <venkatg@...eaurora.org>,
        Bjorn Andersson <bjorn.andersson@...aro.org>,
        Arnd Bergmann <arnd@...db.de>,
        open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v5 3/7] scsi: ufs: Fix up auto hibern8 enablement

Hi Can,

On Thu, 2019-11-14 at 22:09 -0800, Can Guo wrote:
> +	if (hba->ahit != ahit)
> +		hba->ahit = ahit;
>  	spin_unlock_irqrestore(hba->host->host_lock, flags);
> +	if (!pm_runtime_suspended(hba->dev)) {

Always do pm_runtime_get_sync() here could avoid possible racing?

And thus AH8 could be enabled regardless of runtime status.

> +		pm_runtime_get_sync(hba->dev);
> +		ufshcd_hold(hba, false);
> +		ufshcd_auto_hibern8_enable(hba);
> +		ufshcd_release(hba);
> +		pm_runtime_put(hba->dev);
> +	}
>  }

Thanks,
Stanley

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ