From patchwork Thu Feb 29 22:58:48 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Tyler Retzlaff X-Patchwork-Id: 137570 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id D66AF43BAD; Thu, 29 Feb 2024 23:59:08 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8556942F6D; Thu, 29 Feb 2024 23:58:58 +0100 (CET) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mails.dpdk.org (Postfix) with ESMTP id AECE942D2A for ; Thu, 29 Feb 2024 23:58:55 +0100 (CET) Received: by linux.microsoft.com (Postfix, from userid 1086) id C21E220B74C2; Thu, 29 Feb 2024 14:58:54 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com C21E220B74C2 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1709247534; bh=X5RgVHudsFfJcp37lTMGv5Ra7t9dPSiKXUOAQd69cFo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=SFaZ5UFCXVMwGC1MMoj/NkwB1v802XPRVF/UzcYqFYPfDPoHLwp+5pF4k/boK3CZt ulMgAXEz6eEV2V9IirfM/rq0M4dv0jgzO+o7BtrhP7ivDyvE1+G/bWIxpWPyMT5AXl FwBZtvGvvvIFL0fnzdH/cwBZ37OgZnUX3VySaOFY= From: Tyler Retzlaff To: dev@dpdk.org Cc: Bruce Richardson , Cristian Dumitrescu , Honnappa Nagarahalli , Sameh Gobriel , Vladimir Medvedkin , Yipeng Wang , mb@smartsharesystems.com, fengchengwen@huawei.com, Tyler Retzlaff Subject: [PATCH v4 1/6] hash: replace zero length array with flex array Date: Thu, 29 Feb 2024 14:58:48 -0800 Message-Id: <1709247533-32698-2-git-send-email-roretzla@linux.microsoft.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1709247533-32698-1-git-send-email-roretzla@linux.microsoft.com> References: <1706134657-17446-1-git-send-email-roretzla@linux.microsoft.com> <1709247533-32698-1-git-send-email-roretzla@linux.microsoft.com> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Zero length arrays are GNU extension. Replace with standard flex array. Signed-off-by: Tyler Retzlaff Reviewed-by: Honnappa Nagarahalli Reviewed-by: Morten Brørup Acked-by: Chengwen Feng Acked-by: Stephen Hemminger --- lib/hash/rte_thash.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/hash/rte_thash.c b/lib/hash/rte_thash.c index e8de071..1982051 100644 --- a/lib/hash/rte_thash.c +++ b/lib/hash/rte_thash.c @@ -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 From patchwork Thu Feb 29 22:58:49 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Tyler Retzlaff X-Patchwork-Id: 137572 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id C7D2D43BAD; Thu, 29 Feb 2024 23:59:20 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id DE1C442FC5; Thu, 29 Feb 2024 23:59:00 +0100 (CET) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mails.dpdk.org (Postfix) with ESMTP id C357E42DCB for ; Thu, 29 Feb 2024 23:58:55 +0100 (CET) Received: by linux.microsoft.com (Postfix, from userid 1086) id CF29F20B74C3; Thu, 29 Feb 2024 14:58:54 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com CF29F20B74C3 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1709247534; bh=+cryiBIHSDTN39PyKEHWV24moossZjvQ07okD5JLAWo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=AuQvmhhSWKTmyf6fCViFxBniavW+bcARP89rbZ8PBeSI6EVTI2yU1TT+J1vFpT/BD sbtVPuziQDMtJqgscDsMX6pPJDN1g+LzUGqJOO2ALuV30GCK1+mTlVcvEafgyyouJn sHGls3OCYMCLrhlbQfNznc2R4pUTHeFjWozsZ5BQ= From: Tyler Retzlaff To: dev@dpdk.org Cc: Bruce Richardson , Cristian Dumitrescu , Honnappa Nagarahalli , Sameh Gobriel , Vladimir Medvedkin , Yipeng Wang , mb@smartsharesystems.com, fengchengwen@huawei.com, Tyler Retzlaff Subject: [PATCH v4 2/6] rcu: replace zero length array with flex array Date: Thu, 29 Feb 2024 14:58:49 -0800 Message-Id: <1709247533-32698-3-git-send-email-roretzla@linux.microsoft.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1709247533-32698-1-git-send-email-roretzla@linux.microsoft.com> References: <1706134657-17446-1-git-send-email-roretzla@linux.microsoft.com> <1709247533-32698-1-git-send-email-roretzla@linux.microsoft.com> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org 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 Signed-off-by: Tyler Retzlaff Reviewed-by: Honnappa Nagarahalli Reviewed-by: Morten Brørup Acked-by: Chengwen Feng Acked-by: Stephen Hemminger --- 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(-) diff --git a/devtools/libabigail.abignore b/devtools/libabigail.abignore index 645d289..25c73a5 100644 --- a/devtools/libabigail.abignore +++ b/devtools/libabigail.abignore @@ -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} diff --git a/lib/rcu/rcu_qsbr_pvt.h b/lib/rcu/rcu_qsbr_pvt.h index 5fd7ca2..96d05e6 100644 --- a/lib/rcu/rcu_qsbr_pvt.h +++ b/lib/rcu/rcu_qsbr_pvt.h @@ -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_ */ diff --git a/lib/rcu/rte_rcu_qsbr.h b/lib/rcu/rte_rcu_qsbr.h index e7ef788..af9cbea 100644 --- a/lib/rcu/rte_rcu_qsbr.h +++ b/lib/rcu/rte_rcu_qsbr.h @@ -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, From patchwork Thu Feb 29 22:58:50 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Tyler Retzlaff X-Patchwork-Id: 137571 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 40FF043BAD; Thu, 29 Feb 2024 23:59:15 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B447242FA5; Thu, 29 Feb 2024 23:58:59 +0100 (CET) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mails.dpdk.org (Postfix) with ESMTP id B4AD842DBD for ; Thu, 29 Feb 2024 23:58:55 +0100 (CET) Received: by linux.microsoft.com (Postfix, from userid 1086) id DC95B20B74C4; Thu, 29 Feb 2024 14:58:54 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com DC95B20B74C4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1709247534; bh=lNzMhLvW5ioZm0BzUrnsooeJA+PYOUCDszLUIqvB9yU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=JBDMD237NFOvq9+2c/YHLMo9ordzPypkfk1l8HbOR8OknCuLbSuV9t8ihwNM3F2mb fST2O407Rx86vYrwr9EMqq8oKycGWDZGJd2rm1DXaoiMTT1D2RRrH43+Qonhgg2jEO +rccIQunbTsHDgCykUcPJG8yzQXUg1jEBMVZgD6g= From: Tyler Retzlaff To: dev@dpdk.org Cc: Bruce Richardson , Cristian Dumitrescu , Honnappa Nagarahalli , Sameh Gobriel , Vladimir Medvedkin , Yipeng Wang , mb@smartsharesystems.com, fengchengwen@huawei.com, Tyler Retzlaff Subject: [PATCH v4 3/6] fib: replace zero length array with flex array Date: Thu, 29 Feb 2024 14:58:50 -0800 Message-Id: <1709247533-32698-4-git-send-email-roretzla@linux.microsoft.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1709247533-32698-1-git-send-email-roretzla@linux.microsoft.com> References: <1706134657-17446-1-git-send-email-roretzla@linux.microsoft.com> <1709247533-32698-1-git-send-email-roretzla@linux.microsoft.com> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Zero length arrays are GNU extension. Replace with standard flex array. Signed-off-by: Tyler Retzlaff Reviewed-by: Morten Brørup Acked-by: Stephen Hemminger --- lib/fib/dir24_8.h | 2 +- lib/fib/trie.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/fib/dir24_8.h b/lib/fib/dir24_8.h index b0d1a40..5a7b6dd 100644 --- a/lib/fib/dir24_8.h +++ b/lib/fib/dir24_8.h @@ -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 * diff --git a/lib/fib/trie.h b/lib/fib/trie.h index 3cf161a..71ed191 100644 --- a/lib/fib/trie.h +++ b/lib/fib/trie.h @@ -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 From patchwork Thu Feb 29 22:58:52 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Tyler Retzlaff X-Patchwork-Id: 137573 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id E82DE43BAD; Thu, 29 Feb 2024 23:59:28 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 74F5742FFB; Thu, 29 Feb 2024 23:59:03 +0100 (CET) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mails.dpdk.org (Postfix) with ESMTP id 9F72742DCB for ; Thu, 29 Feb 2024 23:58:56 +0100 (CET) Received: by linux.microsoft.com (Postfix, from userid 1086) id 03C0320B74C6; Thu, 29 Feb 2024 14:58:54 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com 03C0320B74C6 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1709247535; bh=PD67OK8ysy+lDczgk7H2gRzrkGLdQPRgmvHV0WSYw8g=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=KkOmt2zSjRjP0KP9D9iPXuaDXoVta8ovKlRpkJx5m/bOW0QciTcOlmnfSj5UET3tf jPA9iHx6PGpVp65W2GYqPJm2hnoEfoCtbx3GRVZ7PV8XSmakqRv/KdI5Uy3i/bZ+p0 PJNyvlIeVJHiNQdMA5KZvzzDssE9prRIiPPDyw5w= From: Tyler Retzlaff To: dev@dpdk.org Cc: Bruce Richardson , Cristian Dumitrescu , Honnappa Nagarahalli , Sameh Gobriel , Vladimir Medvedkin , Yipeng Wang , mb@smartsharesystems.com, fengchengwen@huawei.com, Tyler Retzlaff Subject: [PATCH v4 5/6] lpm: replace zero length array with flex array Date: Thu, 29 Feb 2024 14:58:52 -0800 Message-Id: <1709247533-32698-6-git-send-email-roretzla@linux.microsoft.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1709247533-32698-1-git-send-email-roretzla@linux.microsoft.com> References: <1706134657-17446-1-git-send-email-roretzla@linux.microsoft.com> <1709247533-32698-1-git-send-email-roretzla@linux.microsoft.com> X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Zero length arrays are GNU extension. Replace with standard flex array. Signed-off-by: Tyler Retzlaff Reviewed-by: Morten Brørup --- lib/lpm/rte_lpm6.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/lpm/rte_lpm6.c b/lib/lpm/rte_lpm6.c index 271bc48..08fef82 100644 --- a/lib/lpm/rte_lpm6.c +++ b/lib/lpm/rte_lpm6.c @@ -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. */ }; From patchwork Thu Feb 29 22:58:53 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Tyler Retzlaff X-Patchwork-Id: 137574 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id B4FD743BAD; Thu, 29 Feb 2024 23:59:34 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8A88A43003; Thu, 29 Feb 2024 23:59:04 +0100 (CET) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mails.dpdk.org (Postfix) with ESMTP id 9FD2542DD4 for ; Thu, 29 Feb 2024 23:58:56 +0100 (CET) Received: by linux.microsoft.com (Postfix, from userid 1086) id 10DA320B74C7; Thu, 29 Feb 2024 14:58:54 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com 10DA320B74C7 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1709247535; bh=P0ErWOkaVym0GTuzOgPIj4paU+tA7bW/iAs1TYP09z4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=rl0CQyg4viP9/AxeWp2tK+T5wdxILaSbKb7XRQc+t8k7TI62sxNIF8OZ0dbkqvlZ1 bZt/CuWpLk1ZKGFur1D4PphbUyXjjznjFvP5Bk/96RJ31GRkT6RwBVUNA27mV5n9Uu v+YhGOlDI8vyUSQHP1pUmJmFAs73mSjpmjrPgabc= From: Tyler Retzlaff To: dev@dpdk.org Cc: Bruce Richardson , Cristian Dumitrescu , Honnappa Nagarahalli , Sameh Gobriel , Vladimir Medvedkin , Yipeng Wang , mb@smartsharesystems.com, fengchengwen@huawei.com, Tyler Retzlaff Subject: [PATCH v4 6/6] table: replace zero length array with flex array Date: Thu, 29 Feb 2024 14:58:53 -0800 Message-Id: <1709247533-32698-7-git-send-email-roretzla@linux.microsoft.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1709247533-32698-1-git-send-email-roretzla@linux.microsoft.com> References: <1706134657-17446-1-git-send-email-roretzla@linux.microsoft.com> <1709247533-32698-1-git-send-email-roretzla@linux.microsoft.com> X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Zero length arrays are GNU extension. Replace with standard flex array. Signed-off-by: Tyler Retzlaff Reviewed-by: Morten Brørup --- 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(-) diff --git a/lib/table/rte_table_acl.c b/lib/table/rte_table_acl.c index 83411d2..44d5bb9 100644 --- a/lib/table/rte_table_acl.c +++ b/lib/table/rte_table_acl.c @@ -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; }; diff --git a/lib/table/rte_table_array.c b/lib/table/rte_table_array.c index 80bc2a7..7278282 100644 --- a/lib/table/rte_table_array.c +++ b/lib/table/rte_table_array.c @@ -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 * diff --git a/lib/table/rte_table_hash_cuckoo.c b/lib/table/rte_table_hash_cuckoo.c index 0f4900c..479dd5e 100644 --- a/lib/table/rte_table_hash_cuckoo.c +++ b/lib/table/rte_table_hash_cuckoo.c @@ -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 diff --git a/lib/table/rte_table_hash_ext.c b/lib/table/rte_table_hash_ext.c index 2148d83..601bc95 100644 --- a/lib/table/rte_table_hash_ext.c +++ b/lib/table/rte_table_hash_ext.c @@ -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 diff --git a/lib/table/rte_table_hash_key16.c b/lib/table/rte_table_hash_key16.c index 7734aef..52834cb 100644 --- a/lib/table/rte_table_hash_key16.c +++ b/lib/table/rte_table_hash_key16.c @@ -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 diff --git a/lib/table/rte_table_hash_key32.c b/lib/table/rte_table_hash_key32.c index fcb4348..f123732 100644 --- a/lib/table/rte_table_hash_key32.c +++ b/lib/table/rte_table_hash_key32.c @@ -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 diff --git a/lib/table/rte_table_hash_key8.c b/lib/table/rte_table_hash_key8.c index bbe6562..f4ed220 100644 --- a/lib/table/rte_table_hash_key8.c +++ b/lib/table/rte_table_hash_key8.c @@ -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 diff --git a/lib/table/rte_table_hash_lru.c b/lib/table/rte_table_hash_lru.c index cb4f329..2007c16 100644 --- a/lib/table/rte_table_hash_lru.c +++ b/lib/table/rte_table_hash_lru.c @@ -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 diff --git a/lib/table/rte_table_lpm.c b/lib/table/rte_table_lpm.c index b9cff25..6773582 100644 --- a/lib/table/rte_table_lpm.c +++ b/lib/table/rte_table_lpm.c @@ -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 * diff --git a/lib/table/rte_table_lpm_ipv6.c b/lib/table/rte_table_lpm_ipv6.c index e4e823a..8e38557 100644 --- a/lib/table/rte_table_lpm_ipv6.c +++ b/lib/table/rte_table_lpm_ipv6.c @@ -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 *