[PATCH v2 10/14] common/sfc_efx/base: fix annotation in netport stat describe
Ivan Malov
ivan.malov at arknetworks.am
Wed Aug 12 19:08:30 CEST 2026
From: Andy Moreton <andy.moreton at amd.com>
Code analysis reported a NULL dereference of the lut parameter.
Fix the annotation to show it is not optional (must be non-NULL).
Fixes: f2f77453cb9f ("common/sfc_efx/base: fill in software LUT for MAC statistics")
Cc: stable at dpdk.org
Signed-off-by: Andy Moreton <andy.moreton at amd.com>
Reviewed-by: Ivan Malov <ivan.malov at arknetworks.am>
Reviewed-by: Viacheslav Galaktionov <viacheslav.galaktionov at arknetworks.am>
---
drivers/common/sfc_efx/base/efx_np.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/common/sfc_efx/base/efx_np.c b/drivers/common/sfc_efx/base/efx_np.c
index 6cf5aeac11..86e5d11506 100644
--- a/drivers/common/sfc_efx/base/efx_np.c
+++ b/drivers/common/sfc_efx/base/efx_np.c
@@ -734,7 +734,7 @@ static void
efx_np_stat_describe(
__in uint8_t *hw_entry_buf,
__in unsigned int lut_nentries,
- __out_ecount_opt(lut_nentries) efx_np_stat_t *lut)
+ __out_ecount(lut_nentries) efx_np_stat_t *lut)
{
const efx_np_stat_t *map;
efx_mac_stat_t sw_id;
--
2.47.3
More information about the dev
mailing list