[Intel-wired-lan] [PATCH net v1] i40e: Fix the timeliness of stats after deleting tc
Jedrzej Jagielski
jedrzej.jagielski at intel.com
Tue Dec 14 10:12:08 UTC 2021
There was an issue with ethtool stats that
have not been cleared after tc had been deleted.
Fix this by resetting stats after deleting tc
by calling i40e_vsi_reset_stats() function
after distroying qdisc.
Fixes: 41c445ff0f48 ("i40e: main driver core")
Signed-off-by: Grzegorz Szczurek <grzegorzx.szczurek at intel.com>
Signed-off-by: Jedrzej Jagielski <jedrzej.jagielski at intel.com>
---
drivers/net/ethernet/intel/i40e/i40e_main.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/net/ethernet/intel/i40e/i40e_main.c b/drivers/net/ethernet/intel/i40e/i40e_main.c
index 5322f44ed6ce..9a16874337ac 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_main.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_main.c
@@ -5690,6 +5690,11 @@ static int i40e_vsi_config_tc(struct i40e_vsi *vsi, u8 enabled_tc)
/* Update the netdev TC setup */
i40e_vsi_config_netdev_tc(vsi, enabled_tc);
+
+ /* After distroying qdisc reset all stats of the vsi */
+ if (!vsi->mqprio_qopt.qopt.hw)
+ i40e_vsi_reset_stats(vsi);
+
out:
return ret;
}
--
2.27.0
More information about the Intel-wired-lan
mailing list