caam_init_rng was erroneously passed pointer address instead of
rng context pointer. This results in Linux compilation warnings
Cc: <[email protected]> # 3.13.6: 6e4e603: crypto: caam - Dynamic memory
Cc: <[email protected]> # 3.13.6
Signed-off-by: Yashpal Dutta <[email protected]>
---
drivers/crypto/caam/caamrng.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/crypto/caam/caamrng.c b/drivers/crypto/caam/caamrng.c
index 403d8d5..3529b54 100644
--- a/drivers/crypto/caam/caamrng.c
+++ b/drivers/crypto/caam/caamrng.c
@@ -290,7 +290,7 @@ static int __init caam_rng_init(void)
rng_ctx = kmalloc(sizeof(struct caam_rng_ctx), GFP_DMA);
if (!rng_ctx)
return -ENOMEM;
- caam_init_rng(&rng_ctx, dev);
+ caam_init_rng(rng_ctx, dev);
dev_info(dev, "registering rng-caam\n");
return hwrng_register(&caam_rng);
--
1.8.1.2
Acked-by: Ruchika Gupta <[email protected]>
> -----Original Message-----
> From: Yashpal Dutta [mailto:[email protected]]
> Sent: Friday, March 21, 2014 12:30 AM
> To: [email protected]; Gupta Ruchika-R66431; Garg Vakul-B16394;
> Geanta Neag Horia Ioan-B05471
> Cc: Dutta Yashpal-B05456; [email protected]
> Subject: [PATCH v2] crypto: caam - fix caamrng compilation warning
>
> caam_init_rng was erroneously passed pointer address instead of rng context
> pointer. This results in Linux compilation warnings
>
> Cc: <[email protected]> # 3.13.6: 6e4e603: crypto: caam - Dynamic
> memory
> Cc: <[email protected]> # 3.13.6
> Signed-off-by: Yashpal Dutta <[email protected]>
> ---
> drivers/crypto/caam/caamrng.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/crypto/caam/caamrng.c b/drivers/crypto/caam/caamrng.c
> index 403d8d5..3529b54 100644
> --- a/drivers/crypto/caam/caamrng.c
> +++ b/drivers/crypto/caam/caamrng.c
> @@ -290,7 +290,7 @@ static int __init caam_rng_init(void)
> rng_ctx = kmalloc(sizeof(struct caam_rng_ctx), GFP_DMA);
> if (!rng_ctx)
> return -ENOMEM;
> - caam_init_rng(&rng_ctx, dev);
> + caam_init_rng(rng_ctx, dev);
>
> dev_info(dev, "registering rng-caam\n");
> return hwrng_register(&caam_rng);
> --
> 1.8.1.2
>