Skip to content

Commit 68fb13a

Browse files
gjb-intelJeff Kirsher
authored andcommitted
i40e: Support firmware CEE DCB UP to TC map re-definition
Changes parsing of FW 4.33 AQ command Get CEE DCBX OPER CFG (0x0A07). Change is required because FW now creates the oper_prio_tc nibbles reversed from those in the CEE Priority Group sub-TLV. This change will only apply to FW 4.33 as future FW versions will use a different function to parse the CEE data. Signed-off-by: Greg Bowers <gregory.j.bowers@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
1 parent 1e99854 commit 68fb13a

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

drivers/net/ethernet/intel/i40e/i40e_dcb.c

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -620,14 +620,17 @@ static void i40e_cee_to_dcb_v1_config(
620620
/* CEE PG data to ETS config */
621621
dcbcfg->etscfg.maxtcs = cee_cfg->oper_num_tc;
622622

623+
/* Note that the FW creates the oper_prio_tc nibbles reversed
624+
* from those in the CEE Priority Group sub-TLV.
625+
*/
623626
for (i = 0; i < 4; i++) {
624-
tc = (u8)((cee_cfg->oper_prio_tc[i] &
625-
I40E_CEE_PGID_PRIO_1_MASK) >>
626-
I40E_CEE_PGID_PRIO_1_SHIFT);
627-
dcbcfg->etscfg.prioritytable[i*2] = tc;
628627
tc = (u8)((cee_cfg->oper_prio_tc[i] &
629628
I40E_CEE_PGID_PRIO_0_MASK) >>
630629
I40E_CEE_PGID_PRIO_0_SHIFT);
630+
dcbcfg->etscfg.prioritytable[i * 2] = tc;
631+
tc = (u8)((cee_cfg->oper_prio_tc[i] &
632+
I40E_CEE_PGID_PRIO_1_MASK) >>
633+
I40E_CEE_PGID_PRIO_1_SHIFT);
631634
dcbcfg->etscfg.prioritytable[i*2 + 1] = tc;
632635
}
633636

0 commit comments

Comments
 (0)