char: hw_random: xgene-rng: removed unneeded call to platform_set_drvdata()
Subsystems (2)
PATCH 1/1 char: hw_random: xgene-rng: 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.
--- drivers/char/hw_random/xgene-rng.c | 1 - 1 file changed, 1 deletion(-)
drivers/char/hw_random/xgene-rng.c +0 -1
@@ -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))
Signature · 1 line
2.34.1
Quoted 24 lines · Andrei Coardos
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 <[email protected]>--- drivers/char/hw_random/xgene-rng.c | 1 - 1 file changed, 1 deletion(-)drivers/char/hw_random/xgene-rng.c +0
-1@@ -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))Signature · 1 line
2.34.1
This one's ok, too. 67fb1e295839 ("hwrng: xgene - Simplify using devm_clk_get_optional_enabled()") removed the platform_get_drvdata call.
Alexandru Ardelean
Reviewed-byQuoted 23 lines · Martin Kaiser
Quoted 19 lines · Andrei Coardos
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 <[email protected]>--- drivers/char/hw_random/xgene-rng.c | 1 - 1 file changed, 1 deletion(-)drivers/char/hw_random/xgene-rng.c +0
-1@@ -321,7 +321,6 @@ static int xgene_rng_probe(struct platform_device *pdev)return -ENOMEM ; ctx->dev = &pdev->dev; -platform_set_drvdata (pdev, ctx);
Quoted 8 lines
Quoted 4 lines
drivers/char/hw_random/xgene-rng.c +0
-1ctx->csr_base =devm_platform_ioremap_resource (pdev,0 );if (IS_ERR (ctx->csr_base)) --2.34.1
This one's ok, too.
67fb1e295839("hwrng: xgene - Simplify usingdevm_clk_get_optional_enabled()") removed theplatform_get_drvdatacall.
Quoted 1 line
Reviewed-by Martin Kaiser <[email protected]>
Herbert Xu
maintainerQuoted 9 lines · Andrei Coardos
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 <[email protected]>--- drivers/char/hw_random/xgene-rng.c | 1 - 1 file changed, 1 deletion(-)
Patch applied. Thanks.
Signature · 3 lines
Email: Herbert Xu <[email protected]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt