net: sched: get rid of struct tc_to_netdev

Get rid of struct tc_to_netdev which is now just unnecessary container
and rather pass per-type structures down to drivers directly.
Along with that, consolidate the naming of per-type structure variables
in cls_*.

Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Acked-by: Jamal Hadi Salim <jhs@mojatatu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Jiri Pirko
2017-08-07 10:15:32 +02:00
committed by David S. Miller
parent 38cf0426e5
commit de4784ca03
33 changed files with 174 additions and 202 deletions

View File

@@ -5657,14 +5657,16 @@ exit:
}
static int __i40e_setup_tc(struct net_device *netdev, enum tc_setup_type type,
struct tc_to_netdev *tc)
void *type_data)
{
struct tc_mqprio_qopt *mqprio = type_data;
if (type != TC_SETUP_MQPRIO)
return -EOPNOTSUPP;
tc->mqprio->hw = TC_MQPRIO_HW_OFFLOAD_TCS;
mqprio->hw = TC_MQPRIO_HW_OFFLOAD_TCS;
return i40e_setup_tc(netdev, tc->mqprio->num_tc);
return i40e_setup_tc(netdev, mqprio->num_tc);
}
/**