drivers: net: use flow block API
This patch updates flow_block_cb_setup_simple() to use the flow block API. Several drivers are also adjusted to use it. This patch introduces the per-driver list of flow blocks to account for blocks that are already in use. Remove tc_block_offload alias. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

gecommit door
David S. Miller

bovenliggende
59094b1e50
commit
955bcb6ea0
@@ -3769,6 +3769,8 @@ static int stmmac_setup_tc_block_cb(enum tc_setup_type type, void *type_data,
|
||||
return ret;
|
||||
}
|
||||
|
||||
static LIST_HEAD(stmmac_block_cb_list);
|
||||
|
||||
static int stmmac_setup_tc(struct net_device *ndev, enum tc_setup_type type,
|
||||
void *type_data)
|
||||
{
|
||||
@@ -3776,7 +3778,8 @@ static int stmmac_setup_tc(struct net_device *ndev, enum tc_setup_type type,
|
||||
|
||||
switch (type) {
|
||||
case TC_SETUP_BLOCK:
|
||||
return flow_block_cb_setup_simple(type_data, NULL,
|
||||
return flow_block_cb_setup_simple(type_data,
|
||||
&stmmac_block_cb_list,
|
||||
stmmac_setup_tc_block_cb,
|
||||
priv, priv, true);
|
||||
case TC_SETUP_QDISC_CBS:
|
||||
|
Verwijs in nieuw issue
Block a user