net: sched: take reference to action dev before calling offloads
In order to remove dependency on rtnl lock when calling hardware offload API, take reference to action mirred dev when initializing flow_action structure in tc_setup_flow_action(). Implement function tc_cleanup_flow_action(), use it to release the device after hardware offload API is done using it. Signed-off-by: Vlad Buslov <vladbu@mellanox.com> Acked-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
9838b20a7f
commit
5a6ff4b13d
@@ -505,6 +505,8 @@ tcf_match_indev(struct sk_buff *skb, int ifindex)
|
||||
|
||||
int tc_setup_flow_action(struct flow_action *flow_action,
|
||||
const struct tcf_exts *exts, bool rtnl_held);
|
||||
void tc_cleanup_flow_action(struct flow_action *flow_action);
|
||||
|
||||
int tc_setup_cb_call(struct tcf_block *block, enum tc_setup_type type,
|
||||
void *type_data, bool err_stop, bool rtnl_held);
|
||||
int tc_setup_cb_add(struct tcf_block *block, struct tcf_proto *tp,
|
||||
|
Reference in New Issue
Block a user