Skip to content

Commit

Permalink
dmaengine: stm32-dmamux: Remove unnecessary platform_get_resource() e…
Browse files Browse the repository at this point in the history
…rror 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>
Acked-by: Pierre-Yves MORDRET <pierre-yves.mordret@st.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
  • Loading branch information
Wei Yongjun authored and Vinod Koul committed Jan 19, 2018
1 parent 4fbd8d1 commit 2cbe23f
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions drivers/dma/stm32-dmamux.c
Original file line number Diff line number Diff line change
Expand Up @@ -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);
Expand Down

0 comments on commit 2cbe23f

Please sign in to comment.