Skip to content

Commit da8badd

Browse files
bvanasschemartinkpetersen
authored andcommitted
scsi: ufs: Simplify ufshcd_clear_cmd()
Remove the local variable 'err'. This patch does not change any functionality. Link: https://lore.kernel.org/r/20220613214442.212466-2-bvanassche@acm.org Reviewed-by: Stanley Chu <stanley.chu@mediatek.com> Reviewed-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Bart Van Assche <bvanassche@acm.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
1 parent f6eed15 commit da8badd

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

drivers/ufs/core/ufshcd.c

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2866,7 +2866,6 @@ static int ufshcd_compose_dev_cmd(struct ufs_hba *hba,
28662866
static int
28672867
ufshcd_clear_cmd(struct ufs_hba *hba, int tag)
28682868
{
2869-
int err = 0;
28702869
unsigned long flags;
28712870
u32 mask = 1 << tag;
28722871

@@ -2879,11 +2878,8 @@ ufshcd_clear_cmd(struct ufs_hba *hba, int tag)
28792878
* wait for h/w to clear corresponding bit in door-bell.
28802879
* max. wait is 1 sec.
28812880
*/
2882-
err = ufshcd_wait_for_register(hba,
2883-
REG_UTP_TRANSFER_REQ_DOOR_BELL,
2884-
mask, ~mask, 1000, 1000);
2885-
2886-
return err;
2881+
return ufshcd_wait_for_register(hba, REG_UTP_TRANSFER_REQ_DOOR_BELL,
2882+
mask, ~mask, 1000, 1000);
28872883
}
28882884

28892885
static int

0 commit comments

Comments
 (0)