提交 4bb1b116 编写于 作者: J Jiri Pirko 提交者: David S. Miller

net: sched: move block offload unbind after all chains are flushed

Currently, the offload unbind is done before the chains are flushed.
That causes driver to unregister block callback before it can get all
the callback calls done during flush, leaving the offloaded tps inside
the HW. So fix the order to prevent this situation and restore the
original behaviour.
Reported-by: NAlexander Duyck <alexander.duyck@gmail.com>
Reported-by: NJakub Kicinski <kubakici@wp.pl>
Signed-off-by: NJiri Pirko <jiri@mellanox.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 9a7b96b3
......@@ -343,11 +343,11 @@ void tcf_block_put_ext(struct tcf_block *block,
if (!block)
return;
tcf_block_offload_unbind(block, q, ei);
list_for_each_entry_safe(chain, tmp, &block->chain_list, list)
tcf_chain_flush(chain);
tcf_block_offload_unbind(block, q, ei);
INIT_WORK(&block->work, tcf_block_put_final);
/* Wait for existing RCU callbacks to cool down, make sure their works
* have been queued before this. We can not flush pending works here
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册