From: Qinglang Miao Date: Mon, 21 Sep 2020 13:10:09 +0000 (+0800) Subject: crypto: mediatek - simplify the return expression of mtk_dfe_dse_reset() X-Git-Tag: v5.10.7~1291^2~32 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=17f86c5b6be5a6bd94d014d27fbbc04ef2d7653f;p=platform%2Fkernel%2Flinux-rpi.git crypto: mediatek - simplify the return expression of mtk_dfe_dse_reset() Simplify the return expression. Signed-off-by: Qinglang Miao Signed-off-by: Herbert Xu --- diff --git a/drivers/crypto/mediatek/mtk-platform.c b/drivers/crypto/mediatek/mtk-platform.c index efce3a8..9d87862 100644 --- a/drivers/crypto/mediatek/mtk-platform.c +++ b/drivers/crypto/mediatek/mtk-platform.c @@ -185,8 +185,6 @@ static int mtk_dfe_dse_state_check(struct mtk_cryp *cryp) static int mtk_dfe_dse_reset(struct mtk_cryp *cryp) { - int err; - /* Reset DSE/DFE and correct system priorities for all rings. */ writel(MTK_DFSE_THR_CTRL_RESET, cryp->base + DFE_THR_CTRL); writel(0, cryp->base + DFE_PRIO_0); @@ -200,11 +198,7 @@ static int mtk_dfe_dse_reset(struct mtk_cryp *cryp) writel(0, cryp->base + DSE_PRIO_2); writel(0, cryp->base + DSE_PRIO_3); - err = mtk_dfe_dse_state_check(cryp); - if (err) - return err; - - return 0; + return mtk_dfe_dse_state_check(cryp); } static void mtk_cmd_desc_ring_setup(struct mtk_cryp *cryp,