Skip to contentSkip to conversation

ice: config netdev tc before setting queues number

PATCH Superseded Michal Swiatkowski 2 participants 3 messages Aug 8, 2022

Subsystems (2)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ice: config netdev tc before setting queues number

After lowering number of tx queues the warning appears:
"Number of in use tx queues changed invalidating tc mappings. Priority traff ic classification disabled!"

Fix this by setting correct tc mapping before setting real number of queues on netdev.

Fixes 0754d65bd4be5 ("ice: Add infrastructure for mqprio support via ndo_setup_tc")
---
 drivers/net/ethernet/intel/ice/ice_main.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/net/ethernet/intel/ice/ice_main.c +2 -0
index d992321e74ba..bb17bcfd2529 100644
@@ -6918,6 +6918,8 @@ int ice_vsi_open(struct ice_vsi *vsi)
 	if (err)
 		goto err_setup_rx;
 
+	ice_vsi_cfg_netdev_tc(vsi, vsi->tc_cfg.ena_tc);
+
 	if (vsi->type == ICE_VSI_PF) {
 		/* Notify the stack of the actual queue counts. */
 		err = netif_set_real_num_tx_queues(vsi->netdev, vsi->num_txq);
Signature · 6 lines
2.36.1

_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
#1 lore raw

Dear Michal,

Thank you for your patch.

Am 08.08.22 um 06:23 schrieb Michal Swiatkowski:

Quoted 3 lines

After lowering number of tx queues the warning appears:
"Number of in use tx queues changed invalidating tc mappings. Priority traff ic classification disabled!"

A space snuck in in *traffic*.

It’d be also nice, if you added the command to lower the tx queues to the commit message.

Quoted 14 lines

Fix this by setting correct tc mapping before setting real number of queues on netdev.

Fixes 0754d65bd4be5 ("ice: Add infrastructure for mqprio support via ndo_setup_tc")
---
  drivers/net/ethernet/intel/ice/ice_main.c | 2 ++
  1 file changed, 2 insertions(+)
drivers/net/ethernet/intel/ice/ice_main.c +0 -0
index d992321e74ba..bb17bcfd2529 100644

drivers/net/ethernet/intel/ice/ice_main.c int ice_vsi_open(struct ice_vsi *vsi) · line 6925

Quoted 8 lines
drivers/net/ethernet/intel/ice/ice_main.c +2 -0
@@ -6918,6 +6918,8 @@ int ice_vsi_open(struct ice_vsi *vsi)
  	if (err)
  		goto err_setup_rx;
 
+	ice_vsi_cfg_netdev_tc(vsi, vsi->tc_cfg.ena_tc);
+
  	if (vsi->type == ICE_VSI_PF) {
  		/* Notify the stack of the actual queue counts. */
  		err = netif_set_real_num_tx_queues(vsi->netdev, vsi->num_txq);

Kind regards,

Paul
_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan

#2 lore raw
Quoted 6 lines · Paul Menzel

Dear Michal,

Thank you for your patch.

Am 08.08.22 um 06:23 schrieb Michal Swiatkowski:

Quoted 9 lines
Quoted 3 lines

After lowering number of tx queues the warning appears:
"Number of in use tx queues changed invalidating tc mappings. Priority traff ic classification disabled!"

A space snuck in in *traffic*.

It’d be also nice, if you added the command to lower the tx queues to the commit message.

Thanks, I will fix and add command in v2.

Quoted 25 lines
Quoted 14 lines

Fix this by setting correct tc mapping before setting real number of queues on netdev.

Fixes 0754d65bd4be5 ("ice: Add infrastructure for mqprio support via ndo_setup_tc")
---
  drivers/net/ethernet/intel/ice/ice_main.c | 2 ++
  1 file changed, 2 insertions(+)
drivers/net/ethernet/intel/ice/ice_main.c +0 -0
index d992321e74ba..bb17bcfd2529 100644

drivers/net/ethernet/intel/ice/ice_main.c int ice_vsi_open(struct ice_vsi *vsi) · line 6924

Quoted 7 lines
drivers/net/ethernet/intel/ice/ice_main.c +2 -0
@@ -6918,6 +6918,8 @@ int ice_vsi_open(struct ice_vsi *vsi)
  	if (err)
  		goto err_setup_rx;
+	ice_vsi_cfg_netdev_tc(vsi, vsi->tc_cfg.ena_tc);
+
  	if (vsi->type == ICE_VSI_PF) {
  		/* Notify the stack of the actual queue counts. */
  		err = netif_set_real_num_tx_queues(vsi->netdev, vsi->num_txq);

Kind regards,

Quoted 1 line

Paul

_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan