[v5,09/10] net/cpfl: replace zero length array with flex array

Message ID 20231129024221.57653-10-stephen@networkplumber.org (mailing list archive)
State Accepted
Delegated to: Thomas Monjalon
Headers
Series Replace zero length arrays |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Stephen Hemminger Nov. 29, 2023, 2:39 a.m. UTC
  Zero length arrays are GNU extension. Replace with
standard flex array.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 drivers/net/cpfl/cpfl_flow_engine_fxp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Patch

diff --git a/drivers/net/cpfl/cpfl_flow_engine_fxp.c b/drivers/net/cpfl/cpfl_flow_engine_fxp.c
index 8a4e1419b4db..39a281fa61ee 100644
--- a/drivers/net/cpfl/cpfl_flow_engine_fxp.c
+++ b/drivers/net/cpfl/cpfl_flow_engine_fxp.c
@@ -53,7 +53,7 @@  struct cpfl_rule_info_meta {
 	uint32_t pr_num;			/* number of pattern rules */
 	uint32_t mr_num;			/* number of modification rules */
 	uint32_t rule_num;			/* number of all rules */
-	struct cpfl_rule_info rules[0];
+	struct cpfl_rule_info rules[];
 };
 
 static uint32_t cpfl_fxp_mod_idx_alloc(struct cpfl_adapter_ext *ad);