Skip to contentSkip to conversation

more replacement of zero length array

PATCH Superseded Tyler Retzlaff 8 participants 51 messages Jan 24, 2024 – Jun 11, 2024

lore
Share & tools
lore
#0 lore raw

cover more replacement of zero length array

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

Tyler Retzlaff (2):
hash: replace zero length array with flex array
rcu: replace zero length array with flex array

 lib/hash/rte_thash.c   | 4 ++--
 lib/rcu/rcu_qsbr_pvt.h | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
Signature · 1 line
1.8.3.1
#1 lore raw

PATCH 1/2 hash: replace zero length array with flex array

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/hash/rte_thash.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
lib/hash/rte_thash.c +2 -2
index e8de071..1982051 100644
@@ -80,7 +80,7 @@ struct rte_thash_subtuple_helper {
 	uint32_t	tuple_offset;	/** < Offset in bits of the subtuple */
 	uint32_t	tuple_len;	/** < Length in bits of the subtuple */
 	uint32_t	lsb_msk;	/** < (1 << reta_sz_log) - 1 */
-	__extension__ uint32_t	compl_table[0] __rte_cache_aligned;
+	uint32_t	compl_table[] __rte_cache_aligned;
 	/** < Complementary table */
 };
 
@@ -93,7 +93,7 @@ struct rte_thash_ctx {
 	uint32_t	flags;
 	uint64_t	*matrices;
 	/**< matrices used with rte_thash_gfni implementation */
-	uint8_t		hash_key[0];
+	uint8_t		hash_key[];
 };
 
 int
Signature · 1 line
1.8.3.1
Reviewed-by on v1 1/2
#2 lore raw

RE: [PATCH 1/2] hash: replace zero length array with flex array

Quoted 14 lines

-----Original Message-----
From: Tyler Retzlaff <[email protected]>
Sent: Wednesday, January 24, 2024 4:18 PM
To: [email protected]
Cc: Bruce Richardson <[email protected]>; Honnappa Nagarahalli <[email protected]>; Sameh Gobriel <[email protected]>; Vladimir Medvedkin <[email protected]>; Yipeng Wang <[email protected]>; Stephen Hemminger <[email protected]>; Tyler Retzlaff <[email protected]>
Subject: [PATCH 1/2] hash: replace zero length array with flex array

Quoted 3 lines

Zero length arrays are GNU extension. Replace with standard flex array.

Quoted 28 lines
---
 lib/hash/rte_thash.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
lib/hash/rte_thash.c index e8de071..1982051 renamed from lib/hash/rte_thash.c +0 -0

100644

lib/hash/rte_thash.c +2 -3
@@ -80,7 +80,7 @@ struct rte_thash_subtuple_helper {
 	uint32_t	tuple_offset;	/** < Offset in bits of the subtuple */
 	uint32_t	tuple_len;	/** < Length in bits of the subtuple */
 	uint32_t	lsb_msk;	/** < (1 << reta_sz_log) - 1 */
-	__extension__ uint32_t	compl_table[0] __rte_cache_aligned;
+	uint32_t	compl_table[] __rte_cache_aligned;
 	/** < Complementary table */
 };
 
@@ -93,7 +93,7 @@ struct rte_thash_ctx {
 	uint32_t	flags;
 	uint64_t	*matrices;
 	/**< matrices used with rte_thash_gfni implementation */
-	uint8_t		hash_key[0];
+	uint8_t		hash_key[];
 };
 
 int
--

1.8.3.1

#4 lore raw

PATCH 2/2 rcu: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/rcu/rcu_qsbr_pvt.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/rcu/rcu_qsbr_pvt.h +1 -1
index 5fd7ca2..96d05e6 100644
@@ -52,7 +52,7 @@ struct rte_rcu_qsbr_dq {
  */
 typedef struct {
 	uint64_t token;  /**< Token */
-	uint8_t elem[0]; /**< Pointer to user element */
+	uint8_t elem[]; /**< Pointer to user element */
 } __attribute__((__may_alias__)) __rte_rcu_qsbr_dq_elem_t;
 
 #endif /* _RTE_RCU_QSBR_PVT_H_ */
Signature · 1 line
1.8.3.1
Reviewed-by on v1 2/2
#5 lore raw

RE: [PATCH 2/2] rcu: replace zero length array with flex array

Quoted 14 lines

-----Original Message-----
From: Tyler Retzlaff <[email protected]>
Sent: Wednesday, January 24, 2024 4:18 PM
To: [email protected]
Cc: Bruce Richardson <[email protected]>; Honnappa Nagarahalli <[email protected]>; Sameh Gobriel <[email protected]>; Vladimir Medvedkin <[email protected]>; Yipeng Wang <[email protected]>; Stephen Hemminger <[email protected]>; Tyler Retzlaff <[email protected]>
Subject: [PATCH 2/2] rcu: replace zero length array with flex array

Quoted 3 lines

Zero length arrays are GNU extension. Replace with standard flex array.

Quoted 19 lines
---
 lib/rcu/rcu_qsbr_pvt.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/rcu/rcu_qsbr_pvt.h index renamed from lib/rcu/rcu_qsbr_pvt.h +0 -0

5fd7ca2..96d05e6 100644

lib/rcu/rcu_qsbr_pvt.h +1 -2
@@ -52,7 +52,7 @@ struct rte_rcu_qsbr_dq {
  */
 typedef struct {
 	uint64_t token;  /**< Token */
-	uint8_t elem[0]; /**< Pointer to user element */
+	uint8_t elem[]; /**< Pointer to user element */
 } __attribute__((__may_alias__)) __rte_rcu_qsbr_dq_elem_t;
 
 #endif /* _RTE_RCU_QSBR_PVT_H_ */
--

1.8.3.1

#7 lore raw
In reply to Tyler Retzlaff
Quoted 17 lines · Tyler Retzlaff

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

Tyler Retzlaff (2):
hash: replace zero length array with flex array
rcu: replace zero length array with flex array

 lib/hash/rte_thash.c   | 4 ++--
 lib/rcu/rcu_qsbr_pvt.h | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
#8 lore raw

v2 cover more replacement of zero length array

In reply to Tyler Retzlaff

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

v2:
* added additional patches for fib & pipeline libs. series-acks have been placed only against original hash and rcu patches.

Tyler Retzlaff (4):
hash: replace zero length array with flex array
rcu: replace zero length array with flex array
fib: replace zero length array with flex array
pipeline: replace zero length array with flex array

 lib/fib/dir24_8.h           | 2 +-
 lib/fib/trie.h              | 2 +-
 lib/hash/rte_thash.c        | 4 ++--
 lib/pipeline/rte_pipeline.h | 2 +-
 lib/rcu/rcu_qsbr_pvt.h      | 2 +-
 5 files changed, 6 insertions(+), 6 deletions(-)
Signature · 1 line
1.8.3.1
#9 lore raw

PATCH v2 1/4 hash: replace zero length array with flex array

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/hash/rte_thash.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
lib/hash/rte_thash.c +2 -2
index e8de071..1982051 100644
@@ -80,7 +80,7 @@ struct rte_thash_subtuple_helper {
 	uint32_t	tuple_offset;	/** < Offset in bits of the subtuple */
 	uint32_t	tuple_len;	/** < Length in bits of the subtuple */
 	uint32_t	lsb_msk;	/** < (1 << reta_sz_log) - 1 */
-	__extension__ uint32_t	compl_table[0] __rte_cache_aligned;
+	uint32_t	compl_table[] __rte_cache_aligned;
 	/** < Complementary table */
 };
 
@@ -93,7 +93,7 @@ struct rte_thash_ctx {
 	uint32_t	flags;
 	uint64_t	*matrices;
 	/**< matrices used with rte_thash_gfni implementation */
-	uint8_t		hash_key[0];
+	uint8_t		hash_key[];
 };
 
 int
Signature · 1 line
1.8.3.1
#10 lore raw

PATCH v2 2/4 rcu: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/rcu/rcu_qsbr_pvt.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/rcu/rcu_qsbr_pvt.h +1 -1
index 5fd7ca2..96d05e6 100644
@@ -52,7 +52,7 @@ struct rte_rcu_qsbr_dq {
  */
 typedef struct {
 	uint64_t token;  /**< Token */
-	uint8_t elem[0]; /**< Pointer to user element */
+	uint8_t elem[]; /**< Pointer to user element */
 } __attribute__((__may_alias__)) __rte_rcu_qsbr_dq_elem_t;
 
 #endif /* _RTE_RCU_QSBR_PVT_H_ */
Signature · 1 line
1.8.3.1
#11 lore raw

PATCH v2 3/4 fib: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/fib/dir24_8.h | 2 +-
 lib/fib/trie.h    | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
lib/fib/dir24_8.h +1 -1
index b0d1a40..5a7b6dd 100644
@@ -32,7 +32,7 @@ struct dir24_8_tbl {
 	uint64_t	*tbl8;		/**< tbl8 table. */
 	uint64_t	*tbl8_idxes;	/**< bitmap containing free tbl8 idxes*/
 	/* tbl24 table. */
-	__extension__ uint64_t	tbl24[0] __rte_cache_aligned;
+	uint64_t	tbl24[] __rte_cache_aligned;
 };
 
 static inline void *
lib/fib/trie.h +1 -1
index 3cf161a..71ed191 100644
@@ -36,7 +36,7 @@ struct rte_trie_tbl {
 	uint32_t	*tbl8_pool;	/**< bitmap containing free tbl8 idxes*/
 	uint32_t	tbl8_pool_pos;
 	/* tbl24 table. */
-	__extension__ uint64_t	tbl24[0] __rte_cache_aligned;
+	uint64_t	tbl24[] __rte_cache_aligned;
 };
 
 static inline uint32_t
Signature · 1 line
1.8.3.1
#12 lore raw

PATCH v2 4/4 pipeline: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/pipeline/rte_pipeline.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/pipeline/rte_pipeline.h +1 -1
index ec51b9b..0c7994b 100644
@@ -220,7 +220,7 @@ struct rte_pipeline_table_entry {
 		uint32_t table_id;
 	};
 	/** Start of table entry area for user defined actions and meta-data */
-	__extension__ uint8_t action_data[0];
+	uint8_t action_data[];
 };
 
 /**
Signature · 1 line
1.8.3.1
#13 lore raw
In reply to Tyler Retzlaff
Quoted 20 lines · On Mon, 12 Feb 2024 14:36:02 -0800 Tyler Retzlaff…

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

v2:
* added additional patches for fib & pipeline libs. series-acks have been placed only against original hash and rcu patches.

Tyler Retzlaff (4):
hash: replace zero length array with flex array
rcu: replace zero length array with flex array
fib: replace zero length array with flex array
pipeline: replace zero length array with flex array

Quoted 7 lines
 lib/fib/dir24_8.h           | 2 +-
 lib/fib/trie.h              | 2 +-
 lib/hash/rte_thash.c        | 4 ++--
 lib/pipeline/rte_pipeline.h | 2 +-
 lib/rcu/rcu_qsbr_pvt.h      | 2 +-
 5 files changed, 6 insertions(+), 6 deletions(-)
#14 lore raw
Quoted 34 lines

From: Stephen Hemminger [mailto:[email protected]]
Sent: Monday, 12 February 2024 23.57

Quoted 20 lines · On Mon, 12 Feb 2024 14:36:02 -0800 Tyler Retzlaff…

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

v2:
* added additional patches for fib & pipeline libs. series-acks have been placed only against original hash and rcu patches.

Tyler Retzlaff (4):
hash: replace zero length array with flex array
rcu: replace zero length array with flex array
fib: replace zero length array with flex array
pipeline: replace zero length array with flex array

Quoted 7 lines
 lib/fib/dir24_8.h           | 2 +-
 lib/fib/trie.h              | 2 +-
 lib/hash/rte_thash.c        | 4 ++--
 lib/pipeline/rte_pipeline.h | 2 +-
 lib/rcu/rcu_qsbr_pvt.h      | 2 +-
 5 files changed, 6 insertions(+), 6 deletions(-)
Quoted 1 line
#15 lore raw
In reply to Tyler Retzlaff
Quoted 8 lines · Tyler Retzlaff

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

Quoted 6 lines

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

v2:
* added additional patches for fib & pipeline libs. series-acks have been placed only against original hash and rcu patches.

There seems to be an issue with the ABI check on those changes. After a quick chat with Dodji, I opened a bug for libabigail.

https://sourceware.org/bugzilla/show_bug.cgi?id=31377

Signature · 1 line
David Marchand
#16 lore raw
Quoted 17 lines · David Marchand
Quoted 8 lines · Tyler Retzlaff

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

Quoted 6 lines

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

v2:
* added additional patches for fib & pipeline libs. series-acks have been placed only against original hash and rcu patches.

Quoted 4 lines

There seems to be an issue with the ABI check on those changes. After a quick chat with Dodji, I opened a bug for libabigail.

https://sourceware.org/bugzilla/show_bug.cgi?id=31377

I double checked again and I don't see the struct in question being embedded as a field of another struct/union. So I don't think there should be an ABI change here.

I'm okay with the change being merged but if there is concern I can drop this patch from the series.

Quoted 4 lines
Signature · 2 lines
-- 
David Marchand
#17 lore raw
Quoted 19 lines · Tyler Retzlaff
Quoted 17 lines · David Marchand
Quoted 14 lines · Tyler Retzlaff

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

v2:
* added additional patches for fib & pipeline libs. series-acks have been placed only against original hash and rcu patches.

Quoted 8 lines
Quoted 4 lines

There seems to be an issue with the ABI check on those changes. After a quick chat with Dodji, I opened a bug for libabigail.

https://sourceware.org/bugzilla/show_bug.cgi?id=31377

I double checked again and I don't see the struct in question being embedded as a field of another struct/union. So I don't think there should be an ABI change here.

That was and is still my understanding too.

The message we get when testing this series is:

type size hasn't changed
1 data member change:
'uint8_t action_data[]' has *some* difference
- please report as a bug

which is why I reached out to Dodji (libabigail maintainer).

Dodji explained me that zero length / flex arrays conversion is something he has been working on, and there are still some rough edges.
This message is there so that libabigail community gets more input on real life cases to handle.

Quoted 3 lines

I'm okay with the change being merged but if there is concern I can drop this patch from the series.

At least, we can't merge it in the current form.

If libabigail gets a fix quickly, DPDK CI will still need a released version. So for this patch to be merged now, we need a libabigail suppression rule. I don't see a way to precisely waive this issue, so my suggestion is to silence any change on the concerned structure here (which should be ok, as the pipeline library data struct have been super stable for a couple of years).
Something like:

$ git diff
devtools/libabigail.abignore +2 -0
index 21b8cd6113..d667157909 100644
@@ -33,3 +33,5 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ; Temporary exceptions till next major ABI version ;
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+[suppress_type]
+       name = rte_pipeline_table_entry
Signature · 1 line
David Marchand
#18 lore raw
Quoted 19 lines · David Marchand
Quoted 2 lines

I'm okay with the change being merged but if there is concern I can drop this patch from the series.

At least, we can't merge it in the current form.

If libabigail gets a fix quickly, DPDK CI will still need a released version. So for this patch to be merged now, we need a libabigail suppression rule. I don't see a way to precisely waive this issue, so my suggestion is to silence any change on the concerned structure here (which should be ok, as the pipeline library data struct have been super stable for a couple of years).
Something like:

$ git diff
devtools/libabigail.abignore +0 -0
index 21b8cd6113..d667157909 100644

devtools/libabigail.abignore line 37

Quoted 5 lines
devtools/libabigail.abignore +2 -0
@@ -33,3 +33,5 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ; Temporary exceptions till next major ABI version ;
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+[suppress_type]
+       name = rte_pipeline_table_entry

Dodji confirmed the issue in libabigail and prepared a fix.

DPDK still needs a suppression rule (like the one proposed above) if we want to merge this change before the libabigail fix makes it to all distribs.
Please resubmit this series with my proposal and a comment pointing at libabigail bz squashed in patch 4.

Signature · 1 line
David Marchand
#19 lore raw
Quoted 29 lines · David Marchand
Quoted 19 lines · David Marchand
Quoted 2 lines

I'm okay with the change being merged but if there is concern I can drop this patch from the series.

At least, we can't merge it in the current form.

If libabigail gets a fix quickly, DPDK CI will still need a released version. So for this patch to be merged now, we need a libabigail suppression rule. I don't see a way to precisely waive this issue, so my suggestion is to silence any change on the concerned structure here (which should be ok, as the pipeline library data struct have been super stable for a couple of years).
Something like:

$ git diff
devtools/libabigail.abignore +0 -0
index 21b8cd6113..d667157909 100644

devtools/libabigail.abignore line 37

Quoted 5 lines
devtools/libabigail.abignore +2 -0
@@ -33,3 +33,5 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ; Temporary exceptions till next major ABI version ;
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+[suppress_type]
+       name = rte_pipeline_table_entry

Dodji confirmed the issue in libabigail and prepared a fix.

Quoted 5 lines

DPDK still needs a suppression rule (like the one proposed above) if we want to merge this change before the libabigail fix makes it to all distribs.
Please resubmit this series with my proposal and a comment pointing at libabigail bz squashed in patch 4.

this works out conveniently, i noticed there are a few more instances that i'll try to add to this series so i'll come back with a new rev.

i've marked the series changes requested in patchwork for now.

Quoted 4 lines
Signature · 2 lines
-- 
David Marchand
#20 lore raw
In reply to David Marchand

Hello,

Quoted 1 line · David Marchand

Dodji confirmed the issue in libabigail and prepared a fix.

Yes, that is correct. Sorry for the inconvenience.

The patch fixing this issue in libabigail has been applied to the mainline and is
https://sourceware.org/git/?p=libabigail.git;a=commit;h=3cc1c3423c89c2cfd9d451ab99b71f3a74b35127.

Quoted 3 lines

DPDK still needs a suppression rule (like the one proposed above) if we want to merge this change before the libabigail fix makes it to all distribs.

We can discuss further if you need a "quick" 2.4.1 release as a vehicle to consume the fix or if you can wait for a 2.5 one that might come later.

I agree however that in the mean time, a temporary suppression specification might be warranted.

[...]

Cheers,

Signature · 1 line
		Dodji
#21 lore raw

v3 cover more replacement of zero length array

In reply to Tyler Retzlaff

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

v3:
* add temporary suppression of libabigail bug

    https://sourceware.org/bugzilla/show_bug.cgi?id=31377

* add 2 more patches covering lpm and table (series ack has not been extended)
* add another zero length array missed in rcu and pipeline

v2:
* added additional patches for fib & pipeline libs. series-acks have been placed only against original hash and rcu patches.

Tyler Retzlaff (6):
hash: replace zero length array with flex array
rcu: replace zero length array with flex array
fib: replace zero length array with flex array
pipeline: replace zero length array with flex array
lpm: replace zero length array with flex array
table: replace zero length array with flex array

 devtools/libabigail.abignore      | 2 ++
 lib/fib/dir24_8.h                 | 2 +-
 lib/fib/trie.h                    | 2 +-
 lib/hash/rte_thash.c              | 4 ++--
 lib/lpm/rte_lpm6.c                | 2 +-
 lib/pipeline/rte_pipeline.h       | 2 +-
 lib/pipeline/rte_port_in_action.c | 2 +-
 lib/rcu/rcu_qsbr_pvt.h            | 2 +-
 lib/rcu/rte_rcu_qsbr.h            | 2 +-
 lib/table/rte_table_acl.c         | 2 +-
 lib/table/rte_table_array.c       | 2 +-
 lib/table/rte_table_hash_cuckoo.c | 2 +-
 lib/table/rte_table_hash_ext.c    | 2 +-
 lib/table/rte_table_hash_key16.c  | 2 +-
 lib/table/rte_table_hash_key32.c  | 2 +-
 lib/table/rte_table_hash_key8.c   | 2 +-
 lib/table/rte_table_hash_lru.c    | 2 +-
 lib/table/rte_table_lpm.c         | 2 +-
 lib/table/rte_table_lpm_ipv6.c    | 2 +-
 19 files changed, 21 insertions(+), 19 deletions(-)
Signature · 1 line
1.8.3.1
#22 lore raw

PATCH v3 1/6 hash: replace zero length array with flex array

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/hash/rte_thash.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
lib/hash/rte_thash.c +2 -2
index e8de071..1982051 100644
@@ -80,7 +80,7 @@ struct rte_thash_subtuple_helper {
 	uint32_t	tuple_offset;	/** < Offset in bits of the subtuple */
 	uint32_t	tuple_len;	/** < Length in bits of the subtuple */
 	uint32_t	lsb_msk;	/** < (1 << reta_sz_log) - 1 */
-	__extension__ uint32_t	compl_table[0] __rte_cache_aligned;
+	uint32_t	compl_table[] __rte_cache_aligned;
 	/** < Complementary table */
 };
 
@@ -93,7 +93,7 @@ struct rte_thash_ctx {
 	uint32_t	flags;
 	uint64_t	*matrices;
 	/**< matrices used with rte_thash_gfni implementation */
-	uint8_t		hash_key[0];
+	uint8_t		hash_key[];
 };
 
 int
Signature · 1 line
1.8.3.1
#23 lore raw

PATCH v3 2/6 rcu: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/rcu/rcu_qsbr_pvt.h | 2 +-
 lib/rcu/rte_rcu_qsbr.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
lib/rcu/rcu_qsbr_pvt.h +1 -1
index 5fd7ca2..96d05e6 100644
@@ -52,7 +52,7 @@ struct rte_rcu_qsbr_dq {
  */
 typedef struct {
 	uint64_t token;  /**< Token */
-	uint8_t elem[0]; /**< Pointer to user element */
+	uint8_t elem[]; /**< Pointer to user element */
 } __attribute__((__may_alias__)) __rte_rcu_qsbr_dq_elem_t;
 
 #endif /* _RTE_RCU_QSBR_PVT_H_ */
lib/rcu/rte_rcu_qsbr.h +1 -1
index e7ef788..af9cbea 100644
@@ -106,7 +106,7 @@ struct rte_rcu_qsbr {
 	uint32_t max_threads;
 	/**< Maximum number of threads using this QS variable */
 
-	struct rte_rcu_qsbr_cnt qsbr_cnt[0] __rte_cache_aligned;
+	struct rte_rcu_qsbr_cnt qsbr_cnt[] __rte_cache_aligned;
 	/**< Quiescent state counter array of 'max_threads' elements */
 
 	/**< Registered thread IDs are stored in a bitmap array,
Signature · 1 line
1.8.3.1
#24 lore raw

PATCH v3 3/6 fib: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/fib/dir24_8.h | 2 +-
 lib/fib/trie.h    | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
lib/fib/dir24_8.h +1 -1
index b0d1a40..5a7b6dd 100644
@@ -32,7 +32,7 @@ struct dir24_8_tbl {
 	uint64_t	*tbl8;		/**< tbl8 table. */
 	uint64_t	*tbl8_idxes;	/**< bitmap containing free tbl8 idxes*/
 	/* tbl24 table. */
-	__extension__ uint64_t	tbl24[0] __rte_cache_aligned;
+	uint64_t	tbl24[] __rte_cache_aligned;
 };
 
 static inline void *
lib/fib/trie.h +1 -1
index 3cf161a..71ed191 100644
@@ -36,7 +36,7 @@ struct rte_trie_tbl {
 	uint32_t	*tbl8_pool;	/**< bitmap containing free tbl8 idxes*/
 	uint32_t	tbl8_pool_pos;
 	/* tbl24 table. */
-	__extension__ uint64_t	tbl24[0] __rte_cache_aligned;
+	uint64_t	tbl24[] __rte_cache_aligned;
 };
 
 static inline uint32_t
Signature · 1 line
1.8.3.1
#25 lore raw

PATCH v3 4/6 pipeline: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

Add a temporary suppression for rte_pipeline_table_entry libabigail bug:

Bugzilla ID: https://sourceware.org/bugzilla/show_bug.cgi?id=31377

---
 devtools/libabigail.abignore      | 2 ++
 lib/pipeline/rte_pipeline.h       | 2 +-
 lib/pipeline/rte_port_in_action.c | 2 +-
 3 files changed, 4 insertions(+), 2 deletions(-)
devtools/libabigail.abignore +2 -0
index 645d289..2a23d53 100644
@@ -33,6 +33,8 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ; Temporary exceptions till next major ABI version ;
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+[suppress_type]
+	name = rte_pipeline_table_entry
 
 [suppress_type]
 	name = rte_eth_fp_ops
lib/pipeline/rte_pipeline.h +1 -1
index ec51b9b..0c7994b 100644
@@ -220,7 +220,7 @@ struct rte_pipeline_table_entry {
 		uint32_t table_id;
 	};
 	/** Start of table entry area for user defined actions and meta-data */
-	__extension__ uint8_t action_data[0];
+	uint8_t action_data[];
 };
 
 /**
lib/pipeline/rte_port_in_action.c +1 -1
index 5818973..ebd9b9a 100644
@@ -282,7 +282,7 @@ struct rte_port_in_action_profile *
 struct rte_port_in_action {
 	struct ap_config cfg;
 	struct ap_data data;
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static __rte_always_inline void *
Signature · 1 line
1.8.3.1
#26 lore raw

PATCH v3 5/6 lpm: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/lpm/rte_lpm6.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/lpm/rte_lpm6.c +1 -1
index 271bc48..08fef82 100644
@@ -106,7 +106,7 @@ struct rte_lpm6 {
 
 	struct rte_lpm_tbl8_hdr *tbl8_hdrs; /* array of tbl8 headers */
 
-	struct rte_lpm6_tbl_entry tbl8[0]
+	struct rte_lpm6_tbl_entry tbl8[]
 			__rte_cache_aligned; /**< LPM tbl8 table. */
 };
 
Signature · 1 line
1.8.3.1
#28 lore raw

PATCH v3 6/6 table: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/table/rte_table_acl.c         | 2 +-
 lib/table/rte_table_array.c       | 2 +-
 lib/table/rte_table_hash_cuckoo.c | 2 +-
 lib/table/rte_table_hash_ext.c    | 2 +-
 lib/table/rte_table_hash_key16.c  | 2 +-
 lib/table/rte_table_hash_key32.c  | 2 +-
 lib/table/rte_table_hash_key8.c   | 2 +-
 lib/table/rte_table_hash_lru.c    | 2 +-
 lib/table/rte_table_lpm.c         | 2 +-
 lib/table/rte_table_lpm_ipv6.c    | 2 +-
 10 files changed, 10 insertions(+), 10 deletions(-)
lib/table/rte_table_acl.c +1 -1
index 83411d2..44d5bb9 100644
@@ -47,7 +47,7 @@ struct rte_table_acl {
 	uint8_t *acl_rule_memory; /* Memory to store the rules */
 
 	/* Memory to store the action table and stack of free entries */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 
lib/table/rte_table_array.c +1 -1
index 80bc2a7..7278282 100644
@@ -39,7 +39,7 @@ struct rte_table_array {
 	uint32_t entry_pos_mask;
 
 	/* Internal table */
-	uint8_t array[0] __rte_cache_aligned;
+	uint8_t array[] __rte_cache_aligned;
 } __rte_cache_aligned;
 
 static void *
lib/table/rte_table_hash_cuckoo.c +1 -1
index 0f4900c..479dd5e 100644
@@ -42,7 +42,7 @@ struct rte_table_hash {
 	struct rte_hash *h_table;
 
 	/* Lookup table */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static int
lib/table/rte_table_hash_ext.c +1 -1
index 2148d83..601bc95 100644
@@ -99,7 +99,7 @@ struct rte_table_hash {
 	uint32_t *bkt_ext_stack;
 
 	/* Table memory */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static int
lib/table/rte_table_hash_key16.c +1 -1
index 7734aef..52834cb 100644
@@ -83,7 +83,7 @@ struct rte_table_hash {
 	uint32_t *stack;
 
 	/* Lookup table */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static int
lib/table/rte_table_hash_key32.c +1 -1
index fcb4348..f123732 100644
@@ -83,7 +83,7 @@ struct rte_table_hash {
 	uint32_t *stack;
 
 	/* Lookup table */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static int
lib/table/rte_table_hash_key8.c +1 -1
index bbe6562..f4ed220 100644
@@ -79,7 +79,7 @@ struct rte_table_hash {
 	uint32_t *stack;
 
 	/* Lookup table */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static int
lib/table/rte_table_hash_lru.c +1 -1
index cb4f329..2007c16 100644
@@ -76,7 +76,7 @@ struct rte_table_hash {
 	uint32_t *key_stack;
 
 	/* Table memory */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static int
lib/table/rte_table_lpm.c +1 -1
index b9cff25..6773582 100644
@@ -47,7 +47,7 @@ struct rte_table_lpm {
 
 	/* Next Hop Table (NHT) */
 	uint32_t nht_users[RTE_TABLE_LPM_MAX_NEXT_HOPS];
-	uint8_t nht[0] __rte_cache_aligned;
+	uint8_t nht[] __rte_cache_aligned;
 };
 
 static void *
lib/table/rte_table_lpm_ipv6.c +1 -1
index e4e823a..8e38557 100644
@@ -44,7 +44,7 @@ struct rte_table_lpm_ipv6 {
 
 	/* Next Hop Table (NHT) */
 	uint32_t nht_users[RTE_TABLE_LPM_MAX_NEXT_HOPS];
-	uint8_t nht[0] __rte_cache_aligned;
+	uint8_t nht[] __rte_cache_aligned;
 };
 
 static void *
Signature · 1 line
1.8.3.1
#30 lore raw

v4 cover more replacement of zero length array

In reply to Tyler Retzlaff

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

v4:
* add another temporary suppression of libabigail bug for rte_rcu_qsbr. As with pipeline i cannot see that rte_rcu_qsbr is nested in any other struct.

v3:
* add temporary suppression of libabigail bug

    https://sourceware.org/bugzilla/show_bug.cgi?id=31377

* add 2 more patches covering lpm and table (series ack has not been extended)
* add another zero length array missed in rcu and pipeline

v2:
* added additional patches for fib & pipeline libs. series-acks have been placed only against original hash and rcu patches.

Tyler Retzlaff (6):
hash: replace zero length array with flex array
rcu: replace zero length array with flex array
fib: replace zero length array with flex array
pipeline: replace zero length array with flex array
lpm: replace zero length array with flex array
table: replace zero length array with flex array

 devtools/libabigail.abignore      | 5 +++++
 lib/fib/dir24_8.h                 | 2 +-
 lib/fib/trie.h                    | 2 +-
 lib/hash/rte_thash.c              | 4 ++--
 lib/lpm/rte_lpm6.c                | 2 +-
 lib/pipeline/rte_pipeline.h       | 2 +-
 lib/pipeline/rte_port_in_action.c | 2 +-
 lib/rcu/rcu_qsbr_pvt.h            | 2 +-
 lib/rcu/rte_rcu_qsbr.h            | 2 +-
 lib/table/rte_table_acl.c         | 2 +-
 lib/table/rte_table_array.c       | 2 +-
 lib/table/rte_table_hash_cuckoo.c | 2 +-
 lib/table/rte_table_hash_ext.c    | 2 +-
 lib/table/rte_table_hash_key16.c  | 2 +-
 lib/table/rte_table_hash_key32.c  | 2 +-
 lib/table/rte_table_hash_key8.c   | 2 +-
 lib/table/rte_table_hash_lru.c    | 2 +-
 lib/table/rte_table_lpm.c         | 2 +-
 lib/table/rte_table_lpm_ipv6.c    | 2 +-
 19 files changed, 24 insertions(+), 19 deletions(-)
Signature · 1 line
1.8.3.1
#31 lore raw

PATCH v4 1/6 hash: replace zero length array with flex array

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/hash/rte_thash.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
lib/hash/rte_thash.c +2 -2
index e8de071..1982051 100644
@@ -80,7 +80,7 @@ struct rte_thash_subtuple_helper {
 	uint32_t	tuple_offset;	/** < Offset in bits of the subtuple */
 	uint32_t	tuple_len;	/** < Length in bits of the subtuple */
 	uint32_t	lsb_msk;	/** < (1 << reta_sz_log) - 1 */
-	__extension__ uint32_t	compl_table[0] __rte_cache_aligned;
+	uint32_t	compl_table[] __rte_cache_aligned;
 	/** < Complementary table */
 };
 
@@ -93,7 +93,7 @@ struct rte_thash_ctx {
 	uint32_t	flags;
 	uint64_t	*matrices;
 	/**< matrices used with rte_thash_gfni implementation */
-	uint8_t		hash_key[0];
+	uint8_t		hash_key[];
 };
 
 int
Signature · 1 line
1.8.3.1
#32 lore raw

PATCH v4 2/6 rcu: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

Add a temporary suppression for rte_pipeline_table_entry libabigail bug:

Bugzilla ID: https://sourceware.org/bugzilla/show_bug.cgi?id=31377

---
 devtools/libabigail.abignore | 3 +++
 lib/rcu/rcu_qsbr_pvt.h       | 2 +-
 lib/rcu/rte_rcu_qsbr.h       | 2 +-
 3 files changed, 5 insertions(+), 2 deletions(-)
devtools/libabigail.abignore +3 -0
index 645d289..25c73a5 100644
@@ -35,5 +35,8 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
 [suppress_type]
+	name = rte_rcu_qsbr
+
+[suppress_type]
 	name = rte_eth_fp_ops
 	has_data_member_inserted_between = {offset_of(reserved2), end}
lib/rcu/rcu_qsbr_pvt.h +1 -1
index 5fd7ca2..96d05e6 100644
@@ -52,7 +52,7 @@ struct rte_rcu_qsbr_dq {
  */
 typedef struct {
 	uint64_t token;  /**< Token */
-	uint8_t elem[0]; /**< Pointer to user element */
+	uint8_t elem[]; /**< Pointer to user element */
 } __attribute__((__may_alias__)) __rte_rcu_qsbr_dq_elem_t;
 
 #endif /* _RTE_RCU_QSBR_PVT_H_ */
lib/rcu/rte_rcu_qsbr.h +1 -1
index e7ef788..af9cbea 100644
@@ -106,7 +106,7 @@ struct rte_rcu_qsbr {
 	uint32_t max_threads;
 	/**< Maximum number of threads using this QS variable */
 
-	struct rte_rcu_qsbr_cnt qsbr_cnt[0] __rte_cache_aligned;
+	struct rte_rcu_qsbr_cnt qsbr_cnt[] __rte_cache_aligned;
 	/**< Quiescent state counter array of 'max_threads' elements */
 
 	/**< Registered thread IDs are stored in a bitmap array,
Signature · 1 line
1.8.3.1
#33 lore raw

PATCH v4 3/6 fib: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/fib/dir24_8.h | 2 +-
 lib/fib/trie.h    | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
lib/fib/dir24_8.h +1 -1
index b0d1a40..5a7b6dd 100644
@@ -32,7 +32,7 @@ struct dir24_8_tbl {
 	uint64_t	*tbl8;		/**< tbl8 table. */
 	uint64_t	*tbl8_idxes;	/**< bitmap containing free tbl8 idxes*/
 	/* tbl24 table. */
-	__extension__ uint64_t	tbl24[0] __rte_cache_aligned;
+	uint64_t	tbl24[] __rte_cache_aligned;
 };
 
 static inline void *
lib/fib/trie.h +1 -1
index 3cf161a..71ed191 100644
@@ -36,7 +36,7 @@ struct rte_trie_tbl {
 	uint32_t	*tbl8_pool;	/**< bitmap containing free tbl8 idxes*/
 	uint32_t	tbl8_pool_pos;
 	/* tbl24 table. */
-	__extension__ uint64_t	tbl24[0] __rte_cache_aligned;
+	uint64_t	tbl24[] __rte_cache_aligned;
 };
 
 static inline uint32_t
Signature · 1 line
1.8.3.1
#34 lore raw

PATCH v4 4/6 pipeline: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

Add a temporary suppression for rte_pipeline_table_entry libabigail bug:

Bugzilla ID: https://sourceware.org/bugzilla/show_bug.cgi?id=31377

---
 devtools/libabigail.abignore      | 2 ++
 lib/pipeline/rte_pipeline.h       | 2 +-
 lib/pipeline/rte_port_in_action.c | 2 +-
 3 files changed, 4 insertions(+), 2 deletions(-)
devtools/libabigail.abignore +2 -0
index 25c73a5..5292b63 100644
@@ -33,6 +33,8 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ; Temporary exceptions till next major ABI version ;
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+[suppress_type]
+	name = rte_pipeline_table_entry
 
 [suppress_type]
 	name = rte_rcu_qsbr
lib/pipeline/rte_pipeline.h +1 -1
index ec51b9b..0c7994b 100644
@@ -220,7 +220,7 @@ struct rte_pipeline_table_entry {
 		uint32_t table_id;
 	};
 	/** Start of table entry area for user defined actions and meta-data */
-	__extension__ uint8_t action_data[0];
+	uint8_t action_data[];
 };
 
 /**
lib/pipeline/rte_port_in_action.c +1 -1
index 5818973..ebd9b9a 100644
@@ -282,7 +282,7 @@ struct rte_port_in_action_profile *
 struct rte_port_in_action {
 	struct ap_config cfg;
 	struct ap_data data;
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static __rte_always_inline void *
Signature · 1 line
1.8.3.1
#35 lore raw

PATCH v4 5/6 lpm: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/lpm/rte_lpm6.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/lpm/rte_lpm6.c +1 -1
index 271bc48..08fef82 100644
@@ -106,7 +106,7 @@ struct rte_lpm6 {
 
 	struct rte_lpm_tbl8_hdr *tbl8_hdrs; /* array of tbl8 headers */
 
-	struct rte_lpm6_tbl_entry tbl8[0]
+	struct rte_lpm6_tbl_entry tbl8[]
 			__rte_cache_aligned; /**< LPM tbl8 table. */
 };
 
Signature · 1 line
1.8.3.1
#37 lore raw

PATCH v4 6/6 table: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/table/rte_table_acl.c         | 2 +-
 lib/table/rte_table_array.c       | 2 +-
 lib/table/rte_table_hash_cuckoo.c | 2 +-
 lib/table/rte_table_hash_ext.c    | 2 +-
 lib/table/rte_table_hash_key16.c  | 2 +-
 lib/table/rte_table_hash_key32.c  | 2 +-
 lib/table/rte_table_hash_key8.c   | 2 +-
 lib/table/rte_table_hash_lru.c    | 2 +-
 lib/table/rte_table_lpm.c         | 2 +-
 lib/table/rte_table_lpm_ipv6.c    | 2 +-
 10 files changed, 10 insertions(+), 10 deletions(-)
lib/table/rte_table_acl.c +1 -1
index 83411d2..44d5bb9 100644
@@ -47,7 +47,7 @@ struct rte_table_acl {
 	uint8_t *acl_rule_memory; /* Memory to store the rules */
 
 	/* Memory to store the action table and stack of free entries */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 
lib/table/rte_table_array.c +1 -1
index 80bc2a7..7278282 100644
@@ -39,7 +39,7 @@ struct rte_table_array {
 	uint32_t entry_pos_mask;
 
 	/* Internal table */
-	uint8_t array[0] __rte_cache_aligned;
+	uint8_t array[] __rte_cache_aligned;
 } __rte_cache_aligned;
 
 static void *
lib/table/rte_table_hash_cuckoo.c +1 -1
index 0f4900c..479dd5e 100644
@@ -42,7 +42,7 @@ struct rte_table_hash {
 	struct rte_hash *h_table;
 
 	/* Lookup table */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static int
lib/table/rte_table_hash_ext.c +1 -1
index 2148d83..601bc95 100644
@@ -99,7 +99,7 @@ struct rte_table_hash {
 	uint32_t *bkt_ext_stack;
 
 	/* Table memory */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static int
lib/table/rte_table_hash_key16.c +1 -1
index 7734aef..52834cb 100644
@@ -83,7 +83,7 @@ struct rte_table_hash {
 	uint32_t *stack;
 
 	/* Lookup table */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static int
lib/table/rte_table_hash_key32.c +1 -1
index fcb4348..f123732 100644
@@ -83,7 +83,7 @@ struct rte_table_hash {
 	uint32_t *stack;
 
 	/* Lookup table */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static int
lib/table/rte_table_hash_key8.c +1 -1
index bbe6562..f4ed220 100644
@@ -79,7 +79,7 @@ struct rte_table_hash {
 	uint32_t *stack;
 
 	/* Lookup table */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static int
lib/table/rte_table_hash_lru.c +1 -1
index cb4f329..2007c16 100644
@@ -76,7 +76,7 @@ struct rte_table_hash {
 	uint32_t *key_stack;
 
 	/* Table memory */
-	uint8_t memory[0] __rte_cache_aligned;
+	uint8_t memory[] __rte_cache_aligned;
 };
 
 static int
lib/table/rte_table_lpm.c +1 -1
index b9cff25..6773582 100644
@@ -47,7 +47,7 @@ struct rte_table_lpm {
 
 	/* Next Hop Table (NHT) */
 	uint32_t nht_users[RTE_TABLE_LPM_MAX_NEXT_HOPS];
-	uint8_t nht[0] __rte_cache_aligned;
+	uint8_t nht[] __rte_cache_aligned;
 };
 
 static void *
lib/table/rte_table_lpm_ipv6.c +1 -1
index e4e823a..8e38557 100644
@@ -44,7 +44,7 @@ struct rte_table_lpm_ipv6 {
 
 	/* Next Hop Table (NHT) */
 	uint32_t nht_users[RTE_TABLE_LPM_MAX_NEXT_HOPS];
-	uint8_t nht[0] __rte_cache_aligned;
+	uint8_t nht[] __rte_cache_aligned;
 };
 
 static void *
Signature · 1 line
1.8.3.1
#39 lore raw
In reply to Tyler Retzlaff

ping

Is this one worth closing out as a part of rc2 so it is done?

not sure if it's a priority to have lib ~complete.

Quoted 57 lines · Tyler Retzlaff

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

v4:
* add another temporary suppression of libabigail bug for rte_rcu_qsbr. As with pipeline i cannot see that rte_rcu_qsbr is nested in any other struct.

v3:
* add temporary suppression of libabigail bug

    https://sourceware.org/bugzilla/show_bug.cgi?id=31377

* add 2 more patches covering lpm and table (series ack has not been extended)
* add another zero length array missed in rcu and pipeline

v2:
* added additional patches for fib & pipeline libs. series-acks have been placed only against original hash and rcu patches.

Tyler Retzlaff (6):
hash: replace zero length array with flex array
rcu: replace zero length array with flex array
fib: replace zero length array with flex array
pipeline: replace zero length array with flex array
lpm: replace zero length array with flex array
table: replace zero length array with flex array

 devtools/libabigail.abignore      | 5 +++++
 lib/fib/dir24_8.h                 | 2 +-
 lib/fib/trie.h                    | 2 +-
 lib/hash/rte_thash.c              | 4 ++--
 lib/lpm/rte_lpm6.c                | 2 +-
 lib/pipeline/rte_pipeline.h       | 2 +-
 lib/pipeline/rte_port_in_action.c | 2 +-
 lib/rcu/rcu_qsbr_pvt.h            | 2 +-
 lib/rcu/rte_rcu_qsbr.h            | 2 +-
 lib/table/rte_table_acl.c         | 2 +-
 lib/table/rte_table_array.c       | 2 +-
 lib/table/rte_table_hash_cuckoo.c | 2 +-
 lib/table/rte_table_hash_ext.c    | 2 +-
 lib/table/rte_table_hash_key16.c  | 2 +-
 lib/table/rte_table_hash_key32.c  | 2 +-
 lib/table/rte_table_hash_key8.c   | 2 +-
 lib/table/rte_table_hash_lru.c    | 2 +-
 lib/table/rte_table_lpm.c         | 2 +-
 lib/table/rte_table_lpm_ipv6.c    | 2 +-
 19 files changed, 24 insertions(+), 19 deletions(-)
Signature · 1 line
1.8.3.1
#40 lore raw

v5 cover more replacement of zero length array

In reply to Tyler Retzlaff

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

v5:
* no changes, rebase for upstream merge / conflicts.

v4:
* add another temporary suppression of libabigail bug for rte_rcu_qsbr. As with pipeline i cannot see that rte_rcu_qsbr is nested in any other struct.

v3:
* add temporary suppression of libabigail bug

    https://sourceware.org/bugzilla/show_bug.cgi?id=31377

* add 2 more patches covering lpm and table (series ack has not been extended)
* add another zero length array missed in rcu and pipeline

v2:
* added additional patches for fib & pipeline libs. series-acks have been placed only against original hash and rcu patches.

Tyler Retzlaff (6):
hash: replace zero length array with flex array
rcu: replace zero length array with flex array
fib: replace zero length array with flex array
pipeline: replace zero length array with flex array
lpm: replace zero length array with flex array
table: replace zero length array with flex array

 devtools/libabigail.abignore      | 5 +++++
 lib/fib/dir24_8.h                 | 2 +-
 lib/fib/trie.h                    | 2 +-
 lib/hash/rte_thash.c              | 4 ++--
 lib/lpm/rte_lpm6.c                | 2 +-
 lib/pipeline/rte_pipeline.h       | 2 +-
 lib/pipeline/rte_port_in_action.c | 2 +-
 lib/rcu/rcu_qsbr_pvt.h            | 2 +-
 lib/rcu/rte_rcu_qsbr.h            | 2 +-
 lib/table/rte_table_acl.c         | 2 +-
 lib/table/rte_table_array.c       | 2 +-
 lib/table/rte_table_hash_cuckoo.c | 2 +-
 lib/table/rte_table_hash_ext.c    | 2 +-
 lib/table/rte_table_hash_key16.c  | 2 +-
 lib/table/rte_table_hash_key32.c  | 2 +-
 lib/table/rte_table_hash_key8.c   | 2 +-
 lib/table/rte_table_hash_lru.c    | 2 +-
 lib/table/rte_table_lpm.c         | 2 +-
 lib/table/rte_table_lpm_ipv6.c    | 2 +-
 19 files changed, 24 insertions(+), 19 deletions(-)
Signature · 1 line
1.8.3.1
#41 lore raw

PATCH v5 1/6 hash: replace zero length array with flex array

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/hash/rte_thash.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
lib/hash/rte_thash.c +2 -2
index 68f653f..10721ef 100644
@@ -81,7 +81,7 @@ struct rte_thash_subtuple_helper {
 	uint32_t	tuple_offset;	/** < Offset in bits of the subtuple */
 	uint32_t	tuple_len;	/** < Length in bits of the subtuple */
 	uint32_t	lsb_msk;	/** < (1 << reta_sz_log) - 1 */
-	__extension__ alignas(RTE_CACHE_LINE_SIZE) uint32_t	compl_table[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint32_t	compl_table[];
 	/** < Complementary table */
 };
 
@@ -94,7 +94,7 @@ struct rte_thash_ctx {
 	uint32_t	flags;
 	uint64_t	*matrices;
 	/**< matrices used with rte_thash_gfni implementation */
-	uint8_t		hash_key[0];
+	uint8_t		hash_key[];
 };
 
 int
Signature · 1 line
1.8.3.1
Acked-by on v5 1/6
#42 lore raw

Re: [PATCH v5 1/6] hash: replace zero length array with flex array

Quoted 34 lines · Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
  lib/hash/rte_thash.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
lib/hash/rte_thash.c +2 -2
index 68f653f..10721ef 100644
@@ -81,7 +81,7 @@ struct rte_thash_subtuple_helper {
  	uint32_t	tuple_offset;	/** < Offset in bits of the subtuple */
  	uint32_t	tuple_len;	/** < Length in bits of the subtuple */
  	uint32_t	lsb_msk;	/** < (1 << reta_sz_log) - 1 */
-	__extension__ alignas(RTE_CACHE_LINE_SIZE) uint32_t	compl_table[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint32_t	compl_table[];
  	/** < Complementary table */
  };
 
@@ -94,7 +94,7 @@ struct rte_thash_ctx {
  	uint32_t	flags;
  	uint64_t	*matrices;
  	/**< matrices used with rte_thash_gfni implementation */
-	uint8_t		hash_key[0];
+	uint8_t		hash_key[];
  };
 
  int
Signature · 2 lines
Regards,
Vladimir
#43 lore raw

PATCH v5 2/6 rcu: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

Add a temporary suppression for rte_pipeline_table_entry libabigail bug:

Bugzilla ID: https://sourceware.org/bugzilla/show_bug.cgi?id=31377

---
 devtools/libabigail.abignore | 3 +++
 lib/rcu/rcu_qsbr_pvt.h       | 2 +-
 lib/rcu/rte_rcu_qsbr.h       | 2 +-
 3 files changed, 5 insertions(+), 2 deletions(-)
devtools/libabigail.abignore +3 -0
index 645d289..25c73a5 100644
@@ -35,5 +35,8 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
 [suppress_type]
+	name = rte_rcu_qsbr
+
+[suppress_type]
 	name = rte_eth_fp_ops
 	has_data_member_inserted_between = {offset_of(reserved2), end}
lib/rcu/rcu_qsbr_pvt.h +1 -1
index 5fd7ca2..96d05e6 100644
@@ -52,7 +52,7 @@ struct rte_rcu_qsbr_dq {
  */
 typedef struct {
 	uint64_t token;  /**< Token */
-	uint8_t elem[0]; /**< Pointer to user element */
+	uint8_t elem[]; /**< Pointer to user element */
 } __attribute__((__may_alias__)) __rte_rcu_qsbr_dq_elem_t;
 
 #endif /* _RTE_RCU_QSBR_PVT_H_ */
lib/rcu/rte_rcu_qsbr.h +1 -1
index 0506191..ed3dd6d 100644
@@ -107,7 +107,7 @@ struct __rte_cache_aligned rte_rcu_qsbr {
 	uint32_t max_threads;
 	/**< Maximum number of threads using this QS variable */
 
-	alignas(RTE_CACHE_LINE_SIZE) struct rte_rcu_qsbr_cnt qsbr_cnt[0];
+	alignas(RTE_CACHE_LINE_SIZE) struct rte_rcu_qsbr_cnt qsbr_cnt[];
 	/**< Quiescent state counter array of 'max_threads' elements */
 
 	/**< Registered thread IDs are stored in a bitmap array,
Signature · 1 line
1.8.3.1
#44 lore raw

PATCH v5 3/6 fib: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/fib/dir24_8.h | 2 +-
 lib/fib/trie.h    | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
lib/fib/dir24_8.h +1 -1
index 6d350f7..7125049 100644
@@ -34,7 +34,7 @@ struct dir24_8_tbl {
 	uint64_t	*tbl8;		/**< tbl8 table. */
 	uint64_t	*tbl8_idxes;	/**< bitmap containing free tbl8 idxes*/
 	/* tbl24 table. */
-	__extension__ alignas(RTE_CACHE_LINE_SIZE) uint64_t	tbl24[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint64_t	tbl24[];
 };
 
 static inline void *
lib/fib/trie.h +1 -1
index 36ce1fd..2c20184 100644
@@ -38,7 +38,7 @@ struct rte_trie_tbl {
 	uint32_t	*tbl8_pool;	/**< bitmap containing free tbl8 idxes*/
 	uint32_t	tbl8_pool_pos;
 	/* tbl24 table. */
-	__extension__ alignas(RTE_CACHE_LINE_SIZE) uint64_t	tbl24[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint64_t	tbl24[];
 };
 
 static inline uint32_t
Signature · 1 line
1.8.3.1
Acked-by on v5 3/6
#45 lore raw

Re: [PATCH v5 3/6] fib: replace zero length array with flex array

Quoted 37 lines · Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
  lib/fib/dir24_8.h | 2 +-
  lib/fib/trie.h    | 2 +-
  2 files changed, 2 insertions(+), 2 deletions(-)
lib/fib/dir24_8.h +1 -1
index 6d350f7..7125049 100644
@@ -34,7 +34,7 @@ struct dir24_8_tbl {
  	uint64_t	*tbl8;		/**< tbl8 table. */
  	uint64_t	*tbl8_idxes;	/**< bitmap containing free tbl8 idxes*/
  	/* tbl24 table. */
-	__extension__ alignas(RTE_CACHE_LINE_SIZE) uint64_t	tbl24[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint64_t	tbl24[];
  };
 
  static inline void *
lib/fib/trie.h +1 -1
index 36ce1fd..2c20184 100644
@@ -38,7 +38,7 @@ struct rte_trie_tbl {
  	uint32_t	*tbl8_pool;	/**< bitmap containing free tbl8 idxes*/
  	uint32_t	tbl8_pool_pos;
  	/* tbl24 table. */
-	__extension__ alignas(RTE_CACHE_LINE_SIZE) uint64_t	tbl24[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint64_t	tbl24[];
  };
 
  static inline uint32_t
Signature · 2 lines
Regards,
Vladimir
#46 lore raw

PATCH v5 4/6 pipeline: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

Add a temporary suppression for rte_pipeline_table_entry libabigail bug:

Bugzilla ID: https://sourceware.org/bugzilla/show_bug.cgi?id=31377

---
 devtools/libabigail.abignore      | 2 ++
 lib/pipeline/rte_pipeline.h       | 2 +-
 lib/pipeline/rte_port_in_action.c | 2 +-
 3 files changed, 4 insertions(+), 2 deletions(-)
devtools/libabigail.abignore +2 -0
index 25c73a5..5292b63 100644
@@ -33,6 +33,8 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ; Temporary exceptions till next major ABI version ;
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+[suppress_type]
+	name = rte_pipeline_table_entry
 
 [suppress_type]
 	name = rte_rcu_qsbr
lib/pipeline/rte_pipeline.h +1 -1
index ec51b9b..0c7994b 100644
@@ -220,7 +220,7 @@ struct rte_pipeline_table_entry {
 		uint32_t table_id;
 	};
 	/** Start of table entry area for user defined actions and meta-data */
-	__extension__ uint8_t action_data[0];
+	uint8_t action_data[];
 };
 
 /**
lib/pipeline/rte_port_in_action.c +1 -1
index bbacaff..4127bd2 100644
@@ -283,7 +283,7 @@ struct rte_port_in_action_profile *
 struct rte_port_in_action {
 	struct ap_config cfg;
 	struct ap_data data;
-	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[];
 };
 
 static __rte_always_inline void *
Signature · 1 line
1.8.3.1
#47 lore raw

PATCH v5 5/6 lpm: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/lpm/rte_lpm6.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/lpm/rte_lpm6.c +1 -1
index 46d8f71..5cc1bb2 100644
@@ -107,7 +107,7 @@ struct rte_lpm6 {
 
 	struct rte_lpm_tbl8_hdr *tbl8_hdrs; /* array of tbl8 headers */
 
-	alignas(RTE_CACHE_LINE_SIZE) struct rte_lpm6_tbl_entry tbl8[0];
+	alignas(RTE_CACHE_LINE_SIZE) struct rte_lpm6_tbl_entry tbl8[];
 			/**< LPM tbl8 table. */
 };
 
Signature · 1 line
1.8.3.1
Acked-by on v5 5/6
#48 lore raw

Re: [PATCH v5 5/6] lpm: replace zero length array with flex array

Quoted 22 lines · Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
  lib/lpm/rte_lpm6.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
lib/lpm/rte_lpm6.c +1 -1
index 46d8f71..5cc1bb2 100644
@@ -107,7 +107,7 @@ struct rte_lpm6 {
 
  	struct rte_lpm_tbl8_hdr *tbl8_hdrs; /* array of tbl8 headers */
 
-	alignas(RTE_CACHE_LINE_SIZE) struct rte_lpm6_tbl_entry tbl8[0];
+	alignas(RTE_CACHE_LINE_SIZE) struct rte_lpm6_tbl_entry tbl8[];
  			/**< LPM tbl8 table. */
  };
 
Signature · 2 lines
Regards,
Vladimir
#49 lore raw

PATCH v5 6/6 table: replace zero length array with flex array

In reply to Tyler Retzlaff

Zero length arrays are GNU extension. Replace with standard flex array.

---
 lib/table/rte_table_acl.c         | 2 +-
 lib/table/rte_table_array.c       | 2 +-
 lib/table/rte_table_hash_cuckoo.c | 2 +-
 lib/table/rte_table_hash_ext.c    | 2 +-
 lib/table/rte_table_hash_key16.c  | 2 +-
 lib/table/rte_table_hash_key32.c  | 2 +-
 lib/table/rte_table_hash_key8.c   | 2 +-
 lib/table/rte_table_hash_lru.c    | 2 +-
 lib/table/rte_table_lpm.c         | 2 +-
 lib/table/rte_table_lpm_ipv6.c    | 2 +-
 10 files changed, 10 insertions(+), 10 deletions(-)
lib/table/rte_table_acl.c +1 -1
index 6f3be6f..78779bb 100644
@@ -48,7 +48,7 @@ struct rte_table_acl {
 	uint8_t *acl_rule_memory; /* Memory to store the rules */
 
 	/* Memory to store the action table and stack of free entries */
-	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[];
 };
 
 
lib/table/rte_table_array.c +1 -1
index 71aada4..84b5d67 100644
@@ -40,7 +40,7 @@ struct __rte_cache_aligned rte_table_array {
 	uint32_t entry_pos_mask;
 
 	/* Internal table */
-	alignas(RTE_CACHE_LINE_SIZE) uint8_t array[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint8_t array[];
 };
 
 static void *
lib/table/rte_table_hash_cuckoo.c +1 -1
index 04668ca..388eae9 100644
@@ -44,7 +44,7 @@ struct rte_table_hash {
 	struct rte_hash *h_table;
 
 	/* Lookup table */
-	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[];
 };
 
 static int
lib/table/rte_table_hash_ext.c +1 -1
index ed93f24..91e5037 100644
@@ -100,7 +100,7 @@ struct rte_table_hash {
 	uint32_t *bkt_ext_stack;
 
 	/* Table memory */
-	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[];
 };
 
 static int
lib/table/rte_table_hash_key16.c +1 -1
index 6141815..67b77c1 100644
@@ -85,7 +85,7 @@ struct rte_table_hash {
 	uint32_t *stack;
 
 	/* Lookup table */
-	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[];
 };
 
 static int
lib/table/rte_table_hash_key32.c +1 -1
index c8f59ad..1aa86c6 100644
@@ -85,7 +85,7 @@ struct rte_table_hash {
 	uint32_t *stack;
 
 	/* Lookup table */
-	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[];
 };
 
 static int
lib/table/rte_table_hash_key8.c +1 -1
index cd91a0e..c8d72b3 100644
@@ -81,7 +81,7 @@ struct rte_table_hash {
 	uint32_t *stack;
 
 	/* Lookup table */
-	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[];
 };
 
 static int
lib/table/rte_table_hash_lru.c +1 -1
index 7b67b99..801e48f 100644
@@ -77,7 +77,7 @@ struct rte_table_hash {
 	uint32_t *key_stack;
 
 	/* Table memory */
-	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint8_t memory[];
 };
 
 static int
lib/table/rte_table_lpm.c +1 -1
index 89f8323..3e10c14 100644
@@ -48,7 +48,7 @@ struct rte_table_lpm {
 
 	/* Next Hop Table (NHT) */
 	uint32_t nht_users[RTE_TABLE_LPM_MAX_NEXT_HOPS];
-	alignas(RTE_CACHE_LINE_SIZE) uint8_t nht[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint8_t nht[];
 };
 
 static void *
lib/table/rte_table_lpm_ipv6.c +1 -1
index 3dec5dd..c1a7412 100644
@@ -45,7 +45,7 @@ struct rte_table_lpm_ipv6 {
 
 	/* Next Hop Table (NHT) */
 	uint32_t nht_users[RTE_TABLE_LPM_MAX_NEXT_HOPS];
-	alignas(RTE_CACHE_LINE_SIZE) uint8_t nht[0];
+	alignas(RTE_CACHE_LINE_SIZE) uint8_t nht[];
 };
 
 static void *
Signature · 1 line
1.8.3.1
#50 lore raw
In reply to Tyler Retzlaff
Quoted 50 lines · Tyler Retzlaff

Replace some missed zero length arrays not captured in the original series.
https://patchwork.dpdk.org/project/dpdk/list/?series=30410&state=*

Zero length arrays are a GNU extension that has been superseded by flex arrays.

https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html

v5:
* no changes, rebase for upstream merge / conflicts.

v4:
* add another temporary suppression of libabigail bug for rte_rcu_qsbr. As with pipeline i cannot see that rte_rcu_qsbr is nested in any other struct.

v3:
* add temporary suppression of libabigail bug

    https://sourceware.org/bugzilla/show_bug.cgi?id=31377

* add 2 more patches covering lpm and table (series ack has not been extended)
* add another zero length array missed in rcu and pipeline

v2:
* added additional patches for fib & pipeline libs. series-acks have been placed only against original hash and rcu patches.

Tyler Retzlaff (6):
hash: replace zero length array with flex array
rcu: replace zero length array with flex array
fib: replace zero length array with flex array
pipeline: replace zero length array with flex array
lpm: replace zero length array with flex array
table: replace zero length array with flex array

 devtools/libabigail.abignore      | 5 +++++
 lib/fib/dir24_8.h                 | 2 +-
 lib/fib/trie.h                    | 2 +-
 lib/hash/rte_thash.c              | 4 ++--
 lib/lpm/rte_lpm6.c                | 2 +-
 lib/pipeline/rte_pipeline.h       | 2 +-
 lib/pipeline/rte_port_in_action.c | 2 +-
 lib/rcu/rcu_qsbr_pvt.h            | 2 +-
 lib/rcu/rte_rcu_qsbr.h            | 2 +-
 lib/table/rte_table_acl.c         | 2 +-
 lib/table/rte_table_array.c       | 2 +-
 lib/table/rte_table_hash_cuckoo.c | 2 +-
Quoted 8 lines
 lib/table/rte_table_hash_ext.c    | 2 +-
 lib/table/rte_table_hash_key16.c  | 2 +-
 lib/table/rte_table_hash_key32.c  | 2 +-
 lib/table/rte_table_hash_key8.c   | 2 +-
 lib/table/rte_table_hash_lru.c    | 2 +-
 lib/table/rte_table_lpm.c         | 2 +-
 lib/table/rte_table_lpm_ipv6.c    | 2 +-
 19 files changed, 24 insertions(+), 19 deletions(-)

libabigail 2.5 got released.
I had a try with it in GHA, and the false positive errors around lib/pipeline and lib/rcu are gone.
Yet there may still be people using older version, so let's take this series as is with the temporary exceptions.

Series applied, thanks.

Signature · 1 line
David Marchand