[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200903083738.85345-1-vulab@iscas.ac.cn>
Date: Thu, 3 Sep 2020 08:37:38 +0000
From: Xu Wang <vulab@...as.ac.cn>
To: krzk@...nel.org, vz@...ia.com, k.konieczny@...sung.com,
herbert@...dor.apana.org.au, davem@...emloft.net
Cc: linux-crypto@...r.kernel.org, linux-samsung-soc@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: [PATCH] crypto: s5p-sss: remove redundant null check
Because clk_disable_unprepare already checked NULL clock
parameter, so the additional checks are unnecessary, just remove them.
Signed-off-by: Xu Wang <vulab@...as.ac.cn>
---
drivers/crypto/s5p-sss.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/crypto/s5p-sss.c b/drivers/crypto/s5p-sss.c
index 341433fbcc4a..fdcbfd45c884 100644
--- a/drivers/crypto/s5p-sss.c
+++ b/drivers/crypto/s5p-sss.c
@@ -2307,8 +2307,7 @@ static int s5p_aes_probe(struct platform_device *pdev)
tasklet_kill(&pdata->tasklet);
err_irq:
- if (pdata->pclk)
- clk_disable_unprepare(pdata->pclk);
+ clk_disable_unprepare(pdata->pclk);
err_clk:
clk_disable_unprepare(pdata->clk);
@@ -2338,8 +2337,7 @@ static int s5p_aes_remove(struct platform_device *pdev)
pdata->use_hash = false;
}
- if (pdata->pclk)
- clk_disable_unprepare(pdata->pclk);
+ clk_disable_unprepare(pdata->pclk);
clk_disable_unprepare(pdata->clk);
s5p_dev = NULL;
--
2.17.1
Powered by blists - more mailing lists