mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 1/1] media: xilinx: Use dmaengine_get_copy_align() accessor
@ 2026-11-11 17:13 Frank.Li
  2026-11-11 23:15 ` Laurent Pinchart
  0 siblings, 1 reply; 2+ messages in thread
From: Frank.Li @ 2026-11-11 17:13 UTC (permalink / raw)
  To: Laurent Pinchart, Mauro Carvalho Chehab, Michal Simek,
	open list:XILINX VIDEO IP CORES,
	moderated list:ARM/ZYNQ ARCHITECTURE, open list
  Cc: imx, vkoul, Frank Li

From: Frank Li <Frank.Li@nxp.com>

Replace direct access to dma->dma->device->copy_align with the
dmaengine_get_copy_align() accessor function.

Prepare move struct dma_device to private.

Signed-off-by: Frank Li <Frank.Li@nxp.com>
---
 drivers/media/platform/xilinx/xilinx-dma.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/media/platform/xilinx/xilinx-dma.c b/drivers/media/platform/xilinx/xilinx-dma.c
index ece2116639fc0..e01bb40bc39c7 100644
--- a/drivers/media/platform/xilinx/xilinx-dma.c
+++ b/drivers/media/platform/xilinx/xilinx-dma.c
@@ -710,7 +710,7 @@ int xvip_dma_init(struct xvip_composite_device *xdev, struct xvip_dma *dma,
 		goto error;
 	}
 
-	dma->align = 1 << dma->dma->device->copy_align;
+	dma->align = 1 << dmaengine_get_copy_align(dma->dma);
 
 	ret = video_register_device(&dma->video, VFL_TYPE_VIDEO, -1);
 	if (ret < 0) {
-- 
2.43.0


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH 1/1] media: xilinx: Use dmaengine_get_copy_align() accessor
  2026-11-11 17:13 [PATCH 1/1] media: xilinx: Use dmaengine_get_copy_align() accessor Frank.Li
@ 2026-11-11 23:15 ` Laurent Pinchart
  0 siblings, 0 replies; 2+ messages in thread
From: Laurent Pinchart @ 2026-11-11 23:15 UTC (permalink / raw)
  To: Frank.Li
  Cc: Mauro Carvalho Chehab, Michal Simek,
	open list:XILINX VIDEO IP CORES,
	moderated list:ARM/ZYNQ ARCHITECTURE, open list, imx, vkoul,
	Frank Li, Tomi Valkeinen

On Wed, Nov 11, 2026 at 12:13:24PM -0500, Frank.Li@oss.nxp.com wrote:
> From: Frank Li <Frank.Li@nxp.com>
> 
> Replace direct access to dma->dma->device->copy_align with the
> dmaengine_get_copy_align() accessor function.
> 
> Prepare move struct dma_device to private.

I didn't see a rationale in the commit that introduced
dmaengine_get_copy_align(), and I then saw it here. Without knowing much
about the greater plan of making dma_device private, this patch looks
OK.

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

Tomi, will you handle this with any other ongoing work on
media/platform/xilinx/, or should it get merged separately ?

> Signed-off-by: Frank Li <Frank.Li@nxp.com>
> ---
>  drivers/media/platform/xilinx/xilinx-dma.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/media/platform/xilinx/xilinx-dma.c b/drivers/media/platform/xilinx/xilinx-dma.c
> index ece2116639fc0..e01bb40bc39c7 100644
> --- a/drivers/media/platform/xilinx/xilinx-dma.c
> +++ b/drivers/media/platform/xilinx/xilinx-dma.c
> @@ -710,7 +710,7 @@ int xvip_dma_init(struct xvip_composite_device *xdev, struct xvip_dma *dma,
>  		goto error;
>  	}
>  
> -	dma->align = 1 << dma->dma->device->copy_align;
> +	dma->align = 1 << dmaengine_get_copy_align(dma->dma);
>  
>  	ret = video_register_device(&dma->video, VFL_TYPE_VIDEO, -1);
>  	if (ret < 0) {

-- 
Regards,

Laurent Pinchart

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-11-11 23:15 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-11 17:13 [PATCH 1/1] media: xilinx: Use dmaengine_get_copy_align() accessor Frank.Li
2026-11-11 23:15 ` Laurent Pinchart

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®