net/sched: taprio: replace tc_taprio_qopt_offload :: enable with a "cmd" enum
Inspired from struct flow_cls_offload :: cmd, in order for taprio to be able to report statistics (which is future work), it seems that we need to drill one step further with the ndo_setup_tc(TC_SETUP_QDISC_TAPRIO) multiplexing, and pass the command as part of the common portion of the muxed structure. Since we already have an "enable" variable in tc_taprio_qopt_offload, refactor all drivers to check for "cmd" instead of "enable", and reject every other command except "replace" and "destroy" - to be future proof. Signed-off-by:Vladimir Oltean <vladimir.oltean@nxp.com> Reviewed-by: Horatiu Vultur <horatiu.vultur@microchip.com> # for lan966x Acked-by: Kurt Kanzenbach <kurt@linutronix.de> # hellcreek Reviewed-by:
Muhammad Husaini Zulkifli <muhammad.husaini.zulkifli@intel.com> Reviewed-by:
Gerhard Engleder <gerhard@engleder-embedded.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
Showing
- drivers/net/dsa/hirschmann/hellcreek.c 9 additions, 5 deletionsdrivers/net/dsa/hirschmann/hellcreek.c
- drivers/net/dsa/ocelot/felix_vsc9959.c 3 additions, 1 deletiondrivers/net/dsa/ocelot/felix_vsc9959.c
- drivers/net/dsa/sja1105/sja1105_tas.c 5 additions, 2 deletionsdrivers/net/dsa/sja1105/sja1105_tas.c
- drivers/net/ethernet/engleder/tsnep_selftests.c 6 additions, 6 deletionsdrivers/net/ethernet/engleder/tsnep_selftests.c
- drivers/net/ethernet/engleder/tsnep_tc.c 3 additions, 1 deletiondrivers/net/ethernet/engleder/tsnep_tc.c
- drivers/net/ethernet/freescale/enetc/enetc_qos.c 5 additions, 1 deletiondrivers/net/ethernet/freescale/enetc/enetc_qos.c
- drivers/net/ethernet/intel/igc/igc_main.c 11 additions, 2 deletionsdrivers/net/ethernet/intel/igc/igc_main.c
- drivers/net/ethernet/microchip/lan966x/lan966x_tc.c 8 additions, 2 deletionsdrivers/net/ethernet/microchip/lan966x/lan966x_tc.c
- drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c 5 additions, 2 deletionsdrivers/net/ethernet/stmicro/stmmac/stmmac_tc.c
- drivers/net/ethernet/ti/am65-cpsw-qos.c 8 additions, 3 deletionsdrivers/net/ethernet/ti/am65-cpsw-qos.c
- include/net/pkt_sched.h 6 additions, 1 deletioninclude/net/pkt_sched.h
- net/sched/sch_taprio.c 2 additions, 2 deletionsnet/sched/sch_taprio.c
Loading
Please register or sign in to comment