aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char
diff options
context:
space:
mode:
authorAndrei Coardos <aboutphysycs@gmail.com>2023-08-28 13:23:29 +0300
committerHerbert Xu <herbert@gondor.apana.org.au>2023-09-15 18:29:45 +0800
commit4ff6244696eed0f08398ca500758c85d4b935094 (patch)
treec27999466d669366c4077d1cf8a61bc10b575456 /drivers/char
parentc7e2c4b37e6d54db92a7e74f7e4c015be33601a3 (diff)
downloadlinux-4ff6244696eed0f08398ca500758c85d4b935094.tar.gz
hwrng: xgene - removed unneeded call to platform_set_drvdata()
This function call was found to be unnecessary as there is no equivalent platform_get_drvdata() call to access the private data of the driver. Also, the private data is defined in this driver, so there is no risk of it being accessed outside of this driver file. Signed-off-by: Andrei Coardos <aboutphysycs@gmail.com> Reviewed-by: Martin Kaiser <martin@kaiser.cx> Reviewed-by: Alexandru Ardelean <alex@shruggie.ro> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/char')
-rw-r--r--drivers/char/hw_random/xgene-rng.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/char/hw_random/xgene-rng.c b/drivers/char/hw_random/xgene-rng.c
index 99f4e86ac3e9ad..7382724bf501c2 100644
--- a/drivers/char/hw_random/xgene-rng.c
+++ b/drivers/char/hw_random/xgene-rng.c
@@ -321,7 +321,6 @@ static int xgene_rng_probe(struct platform_device *pdev)
return -ENOMEM;
ctx->dev = &pdev->dev;
- platform_set_drvdata(pdev, ctx);
ctx->csr_base = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(ctx->csr_base))