Commit 222a6c42 authored by Suman Ghosh's avatar Suman Ghosh Committed by Jakub Kicinski

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: ec87f054 ("octeontx2-af: Install TC filter rules in hardware based on priority")
Signed-off-by: default avatarSuman Ghosh <sumang@marvell.com>
Link: https://lore.kernel.org/r/20230727163101.2793453-1-sumang@marvell.comSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent a4989bee
...@@ -841,7 +841,7 @@ static int otx2_tc_update_mcam_table_del_req(struct otx2_nic *nic, ...@@ -841,7 +841,7 @@ static int otx2_tc_update_mcam_table_del_req(struct otx2_nic *nic,
struct list_head *pos, *n; struct list_head *pos, *n;
struct otx2_tc_flow *tmp; struct otx2_tc_flow *tmp;
int i = 0, index = 0; int i = 0, index = 0;
u16 cntr_val; u16 cntr_val = 0;
/* Find and delete the entry from the list and re-install /* Find and delete the entry from the list and re-install
* all the entries from beginning to the index of the * 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, ...@@ -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; int mcam_idx = flow_cfg->max_flows - flow_cfg->nr_flows - 1;
struct otx2_tc_flow *tmp; struct otx2_tc_flow *tmp;
int list_idx, i; int list_idx, i;
u16 cntr_val; u16 cntr_val = 0;
/* Find the index of the entry(list_idx) whose priority /* Find the index of the entry(list_idx) whose priority
* is greater than the new entry and re-install all * is greater than the new entry and re-install all
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment