]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
dmaengine: stm32-dmamux: Remove unnecessary platform_get_resource() error check
authorWei Yongjun <weiyongjun1@huawei.com>
Wed, 17 Jan 2018 11:27:10 +0000 (11:27 +0000)
committerVinod Koul <vinod.koul@intel.com>
Fri, 19 Jan 2018 05:37:50 +0000 (11:07 +0530)
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>
Acked-by: Pierre-Yves MORDRET <pierre-yves.mordret@st.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
drivers/dma/stm32-dmamux.c

index d5db0f6e1ff886f11404ad4712cc98581167edcb..4dbb30cf94acb8462cd50b8123c64259a86f31c9 100644 (file)
@@ -253,9 +253,6 @@ static int stm32_dmamux_probe(struct platform_device *pdev)
        }
 
        res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-       if (!res)
-               return -ENODEV;
-
        iomem = devm_ioremap_resource(&pdev->dev, res);
        if (IS_ERR(iomem))
                return PTR_ERR(iomem);