scsi: ufs: Use 'else' in ufshcd_set_dev_pwr_mode()
Convert if (ret) { ... } if (!ret) { ... } into if (ret) { ... } else { ... }. Reviewed-by: Bean Huo <beanhuo@micron.com> Reviewed-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Bart Van Assche <bvanassche@acm.org> Link: https://lore.kernel.org/r/20221018202958.1902564-6-bvanassche@acm.org Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
parent
1626c7bba1
commit
836d322d73
|
@ -8797,10 +8797,9 @@ static int ufshcd_set_dev_pwr_mode(struct ufs_hba *hba,
|
|||
scsi_print_sense_hdr(sdp, NULL, &sshdr);
|
||||
ret = -EIO;
|
||||
}
|
||||
}
|
||||
|
||||
if (!ret)
|
||||
} else {
|
||||
hba->curr_dev_pwr_mode = pwr_mode;
|
||||
}
|
||||
|
||||
scsi_device_put(sdp);
|
||||
hba->host->eh_noresume = 0;
|
||||
|
|
Loading…
Reference in New Issue