media: xilinx: Use dmaengine_get_copy_align() accessor
PATCH 1/1 media: xilinx: Use dmaengine_get_copy_align() accessor
From: Frank Li <[email protected]>
Replace direct access to dma->dma->device->copy_align with the dmaengine_get_copy_align() accessor function.
Prepare move struct dma_device to private.
--- drivers/media/platform/xilinx/xilinx-dma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/media/platform/xilinx/xilinx-dma.c +1 -1
@@ -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 ) {
Signature · 1 line
2.43.0
Quoted 6 lines · On Wed, Nov 11, 2026 at 12:13:24PM -0500, [email protected] wrote:
From: Frank Li <[email protected]>
Replace direct access to
dma->dma->device->copy_alignwith thedmaengine_get_copy_align()accessor function.Prepare move struct
dma_deviceto 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.
Tomi, will you handle this with any other ongoing work on media/platform/xilinx/, or should it get merged separately ?
Quoted 18 lines
Signed-off-by Frank Li <[email protected]>--- drivers/media/platform/xilinx/xilinx-dma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/media/platform/xilinx/xilinx-dma.c +1
-1@@ -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 ) {
Signature · 3 lines
Regards, Laurent Pinchart
Tomi Valkeinen
Reviewed-byHi,
Quoted 13 lines · Laurent Pinchart
Quoted 6 lines · On Wed, Nov 11, 2026 at 12:13:24PM -0500, [email protected] wrote:
From: Frank Li <[email protected]>
Replace direct access to
dma->dma->device->copy_alignwith thedmaengine_get_copy_align()accessor function.Prepare move struct
dma_deviceto 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 makingdma_deviceprivate, this patch looks OK.
Quoted 4 lines
Reviewed-by Laurent Pinchart <[email protected]>Tomi, will you handle this with any other ongoing work on media/platform/xilinx/, or should it get merged separately ?
This can be merged separately, I don't have any series that I would be sending in the near term future.
Tomi
Quoted 19 lines
Quoted 18 lines
Signed-off-by Frank Li <[email protected]>--- drivers/media/platform/xilinx/xilinx-dma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/media/platform/xilinx/xilinx-dma.c +1
-1@@ -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 ) {