]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
crypto: marvell/cesa - forward devm_ioremap_resource() error code
authorBoris BREZILLON <boris.brezillon@free-electrons.com>
Thu, 17 Mar 2016 09:47:10 +0000 (10:47 +0100)
committerHerbert Xu <herbert@gondor.apana.org.au>
Thu, 17 Mar 2016 11:09:05 +0000 (19:09 +0800)
Forward devm_ioremap_resource() error code instead of returning
-ENOMEM.

Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Reported-by: Russell King - ARM Linux <linux@arm.linux.org.uk>
Fixes: f63601fd616a ("crypto: marvell/cesa - add a new driver for Marvell's CESA")
Cc: <stable@vger.kernel.org> # 4.2+
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/marvell/cesa.c

index 0643e3366e3309de88a03e687a2d5353f5715a22..310f4337a859d46b647526e53cb00339839502ff 100644 (file)
@@ -420,7 +420,7 @@ static int mv_cesa_probe(struct platform_device *pdev)
        res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "regs");
        cesa->regs = devm_ioremap_resource(dev, res);
        if (IS_ERR(cesa->regs))
-               return -ENOMEM;
+               return PTR_ERR(cesa->regs);
 
        ret = mv_cesa_dev_dma_init(cesa);
        if (ret)