aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSuman Ghosh <[email protected]>2023-07-27 16:31:01 +0000
committerJakub Kicinski <[email protected]>2023-07-28 21:02:11 +0000
commit222a6c42e9ef131fd20463bf95d7ce7b39bee2f8 (patch)
treec3b87e89a818533aa1b58690f7e710866a6198b0
parentMerge branch 'eth-bnxt-fix-a-couple-of-w-1-c-1-warnings' (diff)
downloadkernel-222a6c42e9ef131fd20463bf95d7ce7b39bee2f8.tar.gz
kernel-222a6c42e9ef131fd20463bf95d7ce7b39bee2f8.zip
octeontx2-af: Initialize 'cntr_val' to fix uninitialized symbol error
drivers/net/ethernet/marvell/octeontx2/nic/otx2_tc.c:860 otx2_tc_update_mcam_table_del_req() error: uninitialized symbol 'cntr_val'. Fixes: ec87f05402f5 ("octeontx2-af: Install TC filter rules in hardware based on priority") Signed-off-by: Suman Ghosh <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
-rw-r--r--drivers/net/ethernet/marvell/octeontx2/nic/otx2_tc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_tc.c b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_tc.c
index 1e6fc23eca4f..0915a0121316 100644
--- a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_tc.c
+++ b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_tc.c
@@ -841,7 +841,7 @@ static int otx2_tc_update_mcam_table_del_req(struct otx2_nic *nic,
struct list_head *pos, *n;
struct otx2_tc_flow *tmp;
int i = 0, index = 0;
- u16 cntr_val;
+ u16 cntr_val = 0;
/* Find and delete the entry from the list and re-install
* all the entries from beginning to the index of the
@@ -880,7 +880,7 @@ static int otx2_tc_update_mcam_table_add_req(struct otx2_nic *nic,
int mcam_idx = flow_cfg->max_flows - flow_cfg->nr_flows - 1;
struct otx2_tc_flow *tmp;
int list_idx, i;
- u16 cntr_val;
+ u16 cntr_val = 0;
/* Find the index of the entry(list_idx) whose priority
* is greater than the new entry and re-install all