net: stmmac: add RX frame steering based on VLAN priority in tc flower
authorOng Boon Leong <boon.leong.ong@intel.com>
Thu, 18 Mar 2021 17:22:04 +0000 (01:22 +0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 18 Mar 2021 21:17:51 +0000 (14:17 -0700)
commit0e039f5cf86ce2fcb62077a163e7ff3d7b7b7cf3
tree118cf583a33ab2cdc0a727ab27a99780a2cdca70
parentbd0f670e793137fac1f8cc95f1feac99cc081cba
net: stmmac: add RX frame steering based on VLAN priority in tc flower

We extend tc flower to support configuration of VLAN priority-based RX
frame steering hardware offloading.

To map VLAN <PCP> to Traffic Class <TC>:
  $ tc filter add dev <IFNAME> parent ffff: protocol 802.1Q flower \
       vlan_prio <PCP> hw_tc <TC>

  Note: <TC> < N whereby "tc qdisc ... num_tc N ..."

To delete all tc flower configurations:
  $ tc qdisc delete dev <IFNAME> ingress

Signed-off-by: Ong Boon Leong <boon.leong.ong@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c