[PATCH 11/18] crypto: caam - clean-up in caam_init_rng()

Marcin Niestroj m.niestroj at grinn-global.com
Mon Sep 3 04:44:26 PDT 2018


Pick commit f366af462aef1dcaeab0f68b031e5c4c4eb860e1 from Linux
upstream.

    crypto: caam - clean-up in caam_init_rng()

    Clean up the code, as indicated by Coccinelle.

    Cc: Julia Lawall <julia.lawall at lip6.fr>
    Signed-off-by: Horia Geantă <horia.geanta at nxp.com>
    Signed-off-by: Herbert Xu <herbert at gondor.apana.org.au>

Signed-off-by: Marcin Niestroj <m.niestroj at grinn-global.com>
---
 drivers/crypto/caam/caamrng.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/drivers/crypto/caam/caamrng.c b/drivers/crypto/caam/caamrng.c
index b62e3eb77..39a90568d 100644
--- a/drivers/crypto/caam/caamrng.c
+++ b/drivers/crypto/caam/caamrng.c
@@ -242,11 +242,7 @@ static int caam_init_rng(struct caam_rng_ctx *ctx, struct device_d *jrdev)
 	if (err)
 		return err;
 
-	err = caam_init_buf(ctx, 1);
-	if (err)
-		return err;
-
-	return 0;
+	return caam_init_buf(ctx, 1);
 }
 
 int caam_rng_probe(struct device_d *dev, struct device_d *jrdev)
-- 
2.18.0




More information about the barebox mailing list