nfp: forbid disabling hw-tc-offload on representors while offload active
All netdevs which can accept TC offloads must implement .ndo_set_features(). nfp_reprs currently do not do that, which means hw-tc-offload can be turned on and off even when offloads are active. Whether the offloads are active is really a question to nfp_ports, so remove the per-app tc_busy callback indirection thing, and simply count the number of offloaded items in nfp_port structure. Fixes: 8a276873 ("nfp: provide infrastructure for offloading flower based TC filters") Signed-off-by:Jakub Kicinski <jakub.kicinski@netronome.com> Reviewed-by:
Simon Horman <simon.horman@netronome.com> Tested-by:
Pieter Jansen van Vuuren <pieter.jansenvanvuuren@netronome.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
Showing
- drivers/net/ethernet/netronome/nfp/bpf/main.c 1 addition, 8 deletionsdrivers/net/ethernet/netronome/nfp/bpf/main.c
- drivers/net/ethernet/netronome/nfp/flower/offload.c 4 additions, 0 deletionsdrivers/net/ethernet/netronome/nfp/flower/offload.c
- drivers/net/ethernet/netronome/nfp/nfp_app.h 0 additions, 9 deletionsdrivers/net/ethernet/netronome/nfp/nfp_app.h
- drivers/net/ethernet/netronome/nfp/nfp_net_common.c 3 additions, 4 deletionsdrivers/net/ethernet/netronome/nfp/nfp_net_common.c
- drivers/net/ethernet/netronome/nfp/nfp_net_repr.c 1 addition, 0 deletionsdrivers/net/ethernet/netronome/nfp/nfp_net_repr.c
- drivers/net/ethernet/netronome/nfp/nfp_port.c 18 additions, 0 deletionsdrivers/net/ethernet/netronome/nfp/nfp_port.c
- drivers/net/ethernet/netronome/nfp/nfp_port.h 6 additions, 0 deletionsdrivers/net/ethernet/netronome/nfp/nfp_port.h
Loading
Please register or sign in to comment