]> git.baikalelectronics.ru Git - kernel.git/commit
net: sched: use reference counting for tcf blocks on rules update
authorVlad Buslov <vladbu@mellanox.com>
Mon, 24 Sep 2018 16:22:58 +0000 (19:22 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 26 Sep 2018 03:17:36 +0000 (20:17 -0700)
commitf9b9a922e9fb790c1946cb97861922ad4fab9778
tree1a42fbc8920ccbe2d8b7647610bbd9fbd1d74854
parent7d75df8f66344bb9b809e06956e11feacaaa1ac7
net: sched: use reference counting for tcf blocks on rules update

In order to remove dependency on rtnl lock on rules update path, always
take reference to block while using it on rules update path. Change
tcf_block_get() error handling to properly release block with reference
counting, instead of just destroying it, in order to accommodate potential
concurrent users.

Signed-off-by: Vlad Buslov <vladbu@mellanox.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sched/cls_api.c