mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 11:26:02 +09:00
UPSTREAM: scsi: ufs: core: Remove redundant call in ufshcd_add_command_trace()
ufshcd_add_cmd_upiu_trace() will be called later anyway. Simplify code by
moving if-statement.
Link: https://lore.kernel.org/r/20210802180803.100033-1-huobean@gmail.com
Reviewed-by: Avri Altman <avri.altman@wdc.com>
Signed-off-by: Bean Huo <beanhuo@micron.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Bug: 204438323
(cherry picked from commit f0101af435)
Signed-off-by: Bart Van Assche <bvanassche@google.com>
Change-Id: I96120124b178429ee02b0c6e67d78bc8b4e046c3
This commit is contained in:
committed by
Bart Van Assche
parent
3f9a325f48
commit
e0ff4e3d3c
@@ -383,14 +383,11 @@ static void ufshcd_add_command_trace(struct ufs_hba *hba, unsigned int tag,
|
||||
if (!cmd)
|
||||
return;
|
||||
|
||||
if (!trace_ufshcd_command_enabled()) {
|
||||
/* trace UPIU W/O tracing command */
|
||||
ufshcd_add_cmd_upiu_trace(hba, tag, str_t);
|
||||
return;
|
||||
}
|
||||
|
||||
/* trace UPIU also */
|
||||
ufshcd_add_cmd_upiu_trace(hba, tag, str_t);
|
||||
if (!trace_ufshcd_command_enabled())
|
||||
return;
|
||||
|
||||
opcode = cmd->cmnd[0];
|
||||
lba = scsi_get_lba(cmd);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user