[PATCH] dmadev: replace zero length array
Stephen Hemminger
stephen at networkplumber.org
Wed Oct 15 20:59:46 CEST 2025
Use of zero length arrays is Gcc extension.
Found by zero_length_array.cocci.
Fixes: 9674119fbf27 ("dmadev: add enqueue/dequeue operations")
Cc: pbhagavatula at marvell.com
Signed-off-by: Stephen Hemminger <stephen at networkplumber.org>
---
lib/dmadev/rte_dmadev.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/dmadev/rte_dmadev.h b/lib/dmadev/rte_dmadev.h
index 30e168825e..8ae9ee031b 100644
--- a/lib/dmadev/rte_dmadev.h
+++ b/lib/dmadev/rte_dmadev.h
@@ -856,7 +856,7 @@ struct rte_dma_op {
/** Number of destination segments. */
uint16_t nb_dst;
/** Source and destination segments. */
- struct rte_dma_sge src_dst_seg[0];
+ struct rte_dma_sge src_dst_seg[];
};
#ifdef __cplusplus
--
2.47.3
More information about the dev
mailing list