]> www.infradead.org Git - users/jedix/linux-maple.git/commit
octeontx2-pf: Adds TC offload support
authorGeetha sowjanya <gakula@marvell.com>
Thu, 7 Nov 2024 16:08:38 +0000 (21:38 +0530)
committerDavid S. Miller <davem@davemloft.net>
Wed, 13 Nov 2024 11:57:12 +0000 (11:57 +0000)
commit6c40ca957fe5d5982d55fc77d86d9f8ea0b6bba6
tree76d626e8697b19ebc68e50ddf838bb0722036ee6
parentd8dec30b51655bdab2657978982e49b6c13ce3d3
octeontx2-pf: Adds TC offload support

Implements tc offload support for rvu representors.

Usage example:

 - Add tc rule to drop packets with vlan id 3 using port
   representor(Rpf1vf0).

# tc filter add dev Rpf1vf0 protocol 802.1Q parent ffff: flower
   vlan_id 3 vlan_ethtype ipv4 skip_sw action drop

- Redirect packets with vlan id 5 and IPv4 packets to eth1,
  after stripping vlan header.

# tc filter add dev Rpf1vf0 ingress protocol 802.1Q flower vlan_id 5
  vlan_ethtype ipv4 skip_sw action vlan pop action mirred ingress
  redirect dev eth1

Signed-off-by: Geetha sowjanya <gakula@marvell.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/octeontx2/af/rvu_npc_fs.c
drivers/net/ethernet/marvell/octeontx2/af/rvu_rep.c
drivers/net/ethernet/marvell/octeontx2/nic/otx2_common.h
drivers/net/ethernet/marvell/octeontx2/nic/otx2_flows.c
drivers/net/ethernet/marvell/octeontx2/nic/otx2_tc.c
drivers/net/ethernet/marvell/octeontx2/nic/rep.c
drivers/net/ethernet/marvell/octeontx2/nic/rep.h