As the potential failure of the dma_set_mask(), it should be better to check it and return error if fails. Fixes: d76271d22694 ("drm: xlnx: DRM/KMS driver for Xilinx ZynqMP DisplayPort Subsystem") Signed-off-by: Jiasheng Jiang <jiasheng@xxxxxxxxxxx> --- drivers/dma/mmp_tdma.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/dma/mmp_tdma.c b/drivers/dma/mmp_tdma.c index a262e0eb4cc9..e6cf3d174238 100644 --- a/drivers/dma/mmp_tdma.c +++ b/drivers/dma/mmp_tdma.c @@ -722,7 +722,10 @@ static int mmp_tdma_probe(struct platform_device *pdev) tdev->device.residue_granularity = DMA_RESIDUE_GRANULARITY_BURST; tdev->device.descriptor_reuse = true; - dma_set_mask(&pdev->dev, DMA_BIT_MASK(64)); + ret = dma_set_mask(&pdev->dev, DMA_BIT_MASK(64)); + if (ret) + return ret; + platform_set_drvdata(pdev, tdev); ret = dmaenginem_async_device_register(&tdev->device); -- 2.25.1