Skip to content

Commit 2d5efea

Browse files
Shravya Kumbhamvinodkoul
authored andcommitted
dmaengine: xilinx_dma: fix mixed_enum_type coverity warning
Typecast the fls(width -1) with (enum dmaengine_alignment) in xilinx_dma_chan_probe function to fix the coverity warning. Addresses-Coverity: Event mixed_enum_type. Fixes: 9cd4360 ("dma: Add Xilinx AXI Video Direct Memory Access Engine driver support") Signed-off-by: Shravya Kumbham <[email protected]> Signed-off-by: Radhey Shyam Pandey <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Vinod Koul <[email protected]>
1 parent faeb073 commit 2d5efea

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/dma/xilinx/xilinx_dma.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2781,7 +2781,7 @@ static int xilinx_dma_chan_probe(struct xilinx_dma_device *xdev,
27812781
has_dre = false;
27822782

27832783
if (!has_dre)
2784-
xdev->common.copy_align = fls(width - 1);
2784+
xdev->common.copy_align = (enum dmaengine_alignment)fls(width - 1);
27852785

27862786
if (of_device_is_compatible(node, "xlnx,axi-vdma-mm2s-channel") ||
27872787
of_device_is_compatible(node, "xlnx,axi-dma-mm2s-channel") ||

0 commit comments

Comments
 (0)