Skip to content

Commit d29c32e

Browse files
ChanWoo Leemartinkpetersen
authored andcommitted
scsi: ufs: ufs-mediatek: Remove unnecessary return code
Modify to remove unnecessary 'return 0' code. Signed-off-by: ChanWoo Lee <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Bart Van Assche <[email protected]> Signed-off-by: Martin K. Petersen <[email protected]>
1 parent ee8c88c commit d29c32e

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

drivers/ufs/host/ufs-mediatek.c

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1095,7 +1095,7 @@ static void ufs_mtk_setup_clk_gating(struct ufs_hba *hba)
10951095
}
10961096
}
10971097

1098-
static int ufs_mtk_post_link(struct ufs_hba *hba)
1098+
static void ufs_mtk_post_link(struct ufs_hba *hba)
10991099
{
11001100
/* enable unipro clock gating feature */
11011101
ufs_mtk_cfg_unipro_cg(hba, true);
@@ -1106,8 +1106,6 @@ static int ufs_mtk_post_link(struct ufs_hba *hba)
11061106
FIELD_PREP(UFSHCI_AHIBERN8_SCALE_MASK, 3);
11071107

11081108
ufs_mtk_setup_clk_gating(hba);
1109-
1110-
return 0;
11111109
}
11121110

11131111
static int ufs_mtk_link_startup_notify(struct ufs_hba *hba,
@@ -1120,7 +1118,7 @@ static int ufs_mtk_link_startup_notify(struct ufs_hba *hba,
11201118
ret = ufs_mtk_pre_link(hba);
11211119
break;
11221120
case POST_CHANGE:
1123-
ret = ufs_mtk_post_link(hba);
1121+
ufs_mtk_post_link(hba);
11241122
break;
11251123
default:
11261124
ret = -EINVAL;
@@ -1272,9 +1270,8 @@ static int ufs_mtk_suspend(struct ufs_hba *hba, enum ufs_pm_op pm_op,
12721270
struct arm_smccc_res res;
12731271

12741272
if (status == PRE_CHANGE) {
1275-
if (!ufshcd_is_auto_hibern8_supported(hba))
1276-
return 0;
1277-
ufs_mtk_auto_hibern8_disable(hba);
1273+
if (ufshcd_is_auto_hibern8_supported(hba))
1274+
ufs_mtk_auto_hibern8_disable(hba);
12781275
return 0;
12791276
}
12801277

0 commit comments

Comments
 (0)