dmaengine: xilinx: xdma: Fix Judgment of the return value

Fix: make IS_ERR() judge the devm_ioremap_resource() function return.

Fixes: 17ce252266 ("dmaengine: xilinx: xdma: Add xilinx xdma driver")
Signed-off-by: Minjie Du <duminjie@vivo.com>
Acked-by: Michal Simek <michal.simek@amd.com>
Link: https://lore.kernel.org/r/20230705113912.16247-1-duminjie@vivo.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
This commit is contained in:
Minjie Du 2023-07-05 19:39:12 +08:00 committed by Vinod Koul
parent b1e213a9e3
commit a68b48afc0

View file

@ -892,7 +892,7 @@ static int xdma_probe(struct platform_device *pdev)
}
reg_base = devm_ioremap_resource(&pdev->dev, res);
if (!reg_base) {
if (IS_ERR(reg_base)) {
xdma_err(xdev, "ioremap failed");
goto failed;
}