net/intel/fm10k: warning with gcc-16
http://bugs.dpdk.org/show_bug.cgi?id=1822
Bug ID: 1822
Summary: net/intel/fm10k: warning with gcc-16
Product: DPDK
Version: 25.07
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: normal
Priority: Normal
Component: ethdev
Assignee: [email protected]
Reporter: [email protected]Target Milestone: ---
../drivers/net/intel/fm10k/base/fm10k_common.c: In function ‘fm10k_unbind_hw_stats_q’:../drivers/net/intel/fm10k/base/fm10k_common.c:480:62: warning: parameter ‘idx’ set but not used [-Wunused-but-set-parameter=]
480 | void fm10k_unbind_hw_stats_q(struct fm10k_hw_stats_q *q, u32 idx, u32
count)
|
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
PATCH 1/1 net/fm10k: fix build with GCC 16
Build error reported with GCC 16, due to a set but unused variable. Fix the issue by removing the setting of the var and marking it as unused.
../drivers/net/intel/fm10k/base/fm10k_common.c: In function 'fm10k_unbind_hw_stats_q':../drivers/net/intel/fm10k/base/fm10k_common.c:480:62: warning:
parameter 'idx' set but not used [-Wunused-but-set-parameter=]
480 | void fm10k_unbind_hw_stats_q(struct fm10k_hw_stats_q *q, u32 idx, u32 count)
Bugzilla ID: 1822
--- drivers/net/intel/fm10k/base/fm10k_common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/net/intel/fm10k/base/fm10k_common.c +2 -2
@@ -477,11 +477,11 @@ void fm10k_update_hw_stats_q(struct fm10k_hw *hw, struct fm10k_hw_stats_q *q,* Function invalidates the index values for the queues so any updates that * may have happened are ignored and the base for the queue stats is reset. **/ -void fm10k_unbind_hw_stats_q (struct fm10k_hw_stats_q *q,u32 idx,u32 count) +void fm10k_unbind_hw_stats_q(struct fm10k_hw_stats_q *q, u32 idx __rte_unused, u32 count) {u32 i; -for (i =0 ; i < count; i++, idx++, q++) { +for (i =0 ; i < count; i++, q++) { q->rx_stats_idx =0 ; q->tx_stats_idx =0 ; }
Signature · 1 line
2.48.1
Re: [PATCH] net/fm10k: fix build with GCC 16
Quoted 36 lines · Bruce Richardson
Build error reported with GCC 16, due to a set but unused variable. Fix the issue by removing the setting of the var and marking it as unused.
../drivers/net/intel/fm10k/base/fm10k_common.c: In function 'fm10k_unbind_hw_stats_q':../drivers/net/intel/fm10k/base/fm10k_common.c:480:62: warning:
parameter 'idx' set but not used [-Wunused-but-set-parameter=]
480 | voidfm10k_unbind_hw_stats_q(struct fm10k_hw_stats_q *q, u32 idx, u32 count)Bugzilla ID: 1822
Signed-off-by Bruce Richardson <[email protected]>--- drivers/net/intel/fm10k/base/fm10k_common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)drivers/net/intel/fm10k/base/fm10k_common.c +2
-2@@ -477,11 +477,11 @@ void fm10k_update_hw_stats_q(struct fm10k_hw *hw, struct fm10k_hw_stats_q *q,* Function invalidates the index values for the queues so any updates that * may have happened are ignored and the base for the queue stats is reset. **/ -void fm10k_unbind_hw_stats_q (struct fm10k_hw_stats_q *q,u32 idx,u32 count) +void fm10k_unbind_hw_stats_q(struct fm10k_hw_stats_q *q, u32 idx __rte_unused, u32 count) {u32 i; -for (i =0 ; i < count; i++, idx++, q++) { +for (i =0 ; i < count; i++, q++) { q->rx_stats_idx =0 ; q->tx_stats_idx =0 ; }
Signature · 2 lines
Regards, Vladimir
Bruce Richardson
AppliedRe: [PATCH] net/fm10k: fix build with GCC 16
Quoted 10 lines · Vladimir
Quoted 8 lines · Bruce Richardson
Build error reported with GCC 16, due to a set but unused variable. Fix the issue by removing the setting of the var and marking it as unused.
../drivers/net/intel/fm10k/base/fm10k_common.c: In function 'fm10k_unbind_hw_stats_q':../drivers/net/intel/fm10k/base/fm10k_common.c:480:62: warning:
parameter 'idx' set but not used [-Wunused-but-set-parameter=]
480 | voidfm10k_unbind_hw_stats_q(struct fm10k_hw_stats_q *q, u32 idx, u32 count)
Quoted 8 lines
Quoted 6 lines
Bugzilla ID: 1822
Signed-off-by Bruce Richardson <[email protected]>Quoted 1 line
---
Applied to dpdk-next-net-intel.
/Bruce