[PATCH 1/1] media: m2m-deinterlace: use dmaengine_has_cap() instead of dma_has_cap()
From: Frank . Li
Date: Wed Nov 11 2026 - 12:26:16 EST
From: Frank Li <Frank.Li@xxxxxxx>
Replace the open-coded dma_has_cap(DMA_INTERLEAVE,
pcdev->dma_chan->device->cap_mask) with the dmaengine_has_cap()
helper, which encapsulates the capability check and takes the
dma_chan pointer directly.
No functional change and prepare to move struct dma_device to private.
Signed-off-by: Frank Li <Frank.Li@xxxxxxx>
---
drivers/media/platform/m2m-deinterlace.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/media/platform/m2m-deinterlace.c b/drivers/media/platform/m2m-deinterlace.c
index df291b5f7501f..33f05d2baed6a 100644
--- a/drivers/media/platform/m2m-deinterlace.c
+++ b/drivers/media/platform/m2m-deinterlace.c
@@ -924,7 +924,7 @@ static int deinterlace_probe(struct platform_device *pdev)
if (!pcdev->dma_chan)
return -ENODEV;
- if (!dma_has_cap(DMA_INTERLEAVE, pcdev->dma_chan->device->cap_mask)) {
+ if (!dmaengine_has_cap(pcdev->dma_chan, DMA_INTERLEAVE)) {
dev_err(&pdev->dev, "DMA does not support INTERLEAVE\n");
ret = -ENODEV;
goto rel_dma;
--
2.43.0