Re: [PATCH 4/4] scsi: ufs: core: Make use of guard(mutex)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 4/16/24 03:23, Avri Altman wrote:
@@ -5682,9 +5681,8 @@ int ufshcd_write_ee_control(struct ufs_hba *hba)
  {
  	int err;
- mutex_lock(&hba->ee_ctrl_mutex);
+	guard(mutex)(&hba->ee_ctrl_mutex);
  	err = __ufshcd_write_ee_control(hba, hba->ee_ctrl_mask);
-	mutex_unlock(&hba->ee_ctrl_mutex);
  	if (err)
  		dev_err(hba->dev, "%s: failed to write ee control %d\n",
  			__func__, err);

This change moves the dev_err() statement inside the code block
protected by ee_ctrl_mutex. Please do not make such changes in this
patch.

Thanks,

Bart.




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux