Re: [PATCH net-next 2/5] net/sched: taprio: replace tc_taprio_qopt_offload :: enable with a "cmd" enum

Gerhard Engleder
2023-05-30T22:18:34Z

On 30.05.23 11:19, Vladimir Oltean wrote:
> 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>
> ---
> drivers/net/dsa/hirschmann/hellcreek.c | 14 +++++++++-----
> drivers/net/dsa/ocelot/felix_vsc9959.c | 4 +++-
> drivers/net/dsa/sja1105/sja1105_tas.c | 7 +++++--
> drivers/net/ethernet/engleder/tsnep_selftests.c | 12 ++++++------
> drivers/net/ethernet/engleder/tsnep_tc.c | 4 +++-
> drivers/net/ethernet/freescale/enetc/enetc_qos.c | 6 +++++-
> drivers/net/ethernet/intel/igc/igc_main.c | 13 +++++++++++--
> .../net/ethernet/microchip/lan966x/lan966x_tc.c | 10 ++++++++--
> drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c | 7 +++++--
> drivers/net/ethernet/ti/am65-cpsw-qos.c | 11 ++++++++---
> include/net/pkt_sched.h | 7 ++++++-
> net/sched/sch_taprio.c | 4 ++--
> 12 files changed, 71 insertions(+), 28 deletions(-)

Reviewed-by: Gerhard Engleder <gerhard@engleder-embedded.com>