Commit 59a6854a authored by Uwe Kleine-König's avatar Uwe Kleine-König Committed by Herbert Xu

crypto: keembay - Drop if with an always false condition

A platform device's remove callback is only ever called after the probe
callback returned success.

In the case of kmb_ocs_aes_remove() this means that kmb_ocs_aes_probe()
succeeded before and so platform_set_drvdata() was called with a
non-zero argument and platform_get_drvdata() returns non-NULL.

This prepares making remove callbacks return void.
Signed-off-by: default avatarUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 7e1c64db
...@@ -1580,8 +1580,6 @@ static int kmb_ocs_aes_remove(struct platform_device *pdev) ...@@ -1580,8 +1580,6 @@ static int kmb_ocs_aes_remove(struct platform_device *pdev)
struct ocs_aes_dev *aes_dev; struct ocs_aes_dev *aes_dev;
aes_dev = platform_get_drvdata(pdev); aes_dev = platform_get_drvdata(pdev);
if (!aes_dev)
return -ENODEV;
unregister_aes_algs(aes_dev); unregister_aes_algs(aes_dev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment