Skip to content

Commit

Permalink
dmaengine: stedma40: add missing iounmap() on error in d40_probe()
Browse files Browse the repository at this point in the history
[ Upstream commit fffdaba ]

Add the missing iounmap() before return from d40_probe()
in the error handling case.

Fixes: 8d318a5 ("DMAENGINE: Support for ST-Ericssons DMA40 block v3")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Link: https://lore.kernel.org/r/20210518141108.1324127-1-yangyingliang@huawei.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
Yang Yingliang authored and gregkh committed Jun 23, 2021
1 parent c8e0794 commit 6a5fadc
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/dma/ste_dma40.c
Expand Up @@ -3675,6 +3675,9 @@ static int __init d40_probe(struct platform_device *pdev)

kfree(base->lcla_pool.base_unaligned);

if (base->lcpa_base)
iounmap(base->lcpa_base);

if (base->phy_lcpa)
release_mem_region(base->phy_lcpa,
base->lcpa_size);
Expand Down

0 comments on commit 6a5fadc

Please sign in to comment.