diff options
author | Ricardo Ribalda <ribalda@chromium.org> | 2024-05-27 21:08:52 +0000 |
---|---|---|
committer | Hans Verkuil <hverkuil-cisco@xs4all.nl> | 2024-05-31 13:51:16 +0200 |
commit | a93506f670de9fe57e40e18e32c84e73121bca55 (patch) | |
tree | 1aca00a7b2564cfd4d75501c789f25febc3728a2 /drivers/media/platform/xilinx/xilinx-dma.h | |
parent | 669d51f8f45db35a5e44101b90fcc7173088ad28 (diff) | |
download | lwn-a93506f670de9fe57e40e18e32c84e73121bca55.tar.gz lwn-a93506f670de9fe57e40e18e32c84e73121bca55.zip |
media: xilinx: Refactor struct xvip_dma
Replace a single element array with a single field.
The following cocci warning is fixed:
drivers/media/platform/xilinx/xilinx-dma.h:100:19-22: WARNING use flexible-array member instead (https://www.kernel.org/doc/html/latest/process/deprecated.html#zero-length-and-one-element-arrays)
Signed-off-by: Ricardo Ribalda <ribalda@chromium.org>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Diffstat (limited to 'drivers/media/platform/xilinx/xilinx-dma.h')
-rw-r--r-- | drivers/media/platform/xilinx/xilinx-dma.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/platform/xilinx/xilinx-dma.h b/drivers/media/platform/xilinx/xilinx-dma.h index 9c6d4c18d1a9..18f77e1a7b39 100644 --- a/drivers/media/platform/xilinx/xilinx-dma.h +++ b/drivers/media/platform/xilinx/xilinx-dma.h @@ -97,7 +97,7 @@ struct xvip_dma { struct dma_chan *dma; unsigned int align; struct dma_interleaved_template xt; - struct data_chunk sgl[1]; + struct data_chunk sgl; }; #define to_xvip_dma(vdev) container_of(vdev, struct xvip_dma, video) |