diff options
author | weiyongjun \(A\) <weiyongjun1@huawei.com> | 2018-01-17 06:26:47 -0500 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2018-01-25 09:10:29 -0500 |
commit | 235699e2a99fe40c11a377942e60bad11ce4046e (patch) | |
tree | db4f19464f9e81f79271ddead0dd4daf441c738a | |
parent | 466d7b9f6175e4ecd409f619ff9fbbd49467ad66 (diff) |
crypto: axis - remove unnecessary platform_get_resource() error check
devm_ioremap_resource() already checks if the resource is NULL, so
remove the unnecessary platform_get_resource() error check.
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
-rw-r--r-- | drivers/crypto/axis/artpec6_crypto.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/crypto/axis/artpec6_crypto.c b/drivers/crypto/axis/artpec6_crypto.c index 22df6b55e172..0fb8bbf41a8d 100644 --- a/drivers/crypto/axis/artpec6_crypto.c +++ b/drivers/crypto/axis/artpec6_crypto.c | |||
@@ -3042,9 +3042,6 @@ static int artpec6_crypto_probe(struct platform_device *pdev) | |||
3042 | variant = (enum artpec6_crypto_variant)match->data; | 3042 | variant = (enum artpec6_crypto_variant)match->data; |
3043 | 3043 | ||
3044 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); | 3044 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); |
3045 | if (!res) | ||
3046 | return -ENODEV; | ||
3047 | |||
3048 | base = devm_ioremap_resource(&pdev->dev, res); | 3045 | base = devm_ioremap_resource(&pdev->dev, res); |
3049 | if (IS_ERR(base)) | 3046 | if (IS_ERR(base)) |
3050 | return PTR_ERR(base); | 3047 | return PTR_ERR(base); |