]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
net: sched: protect block->chain0 with block->lock
authorVlad Buslov <vladbu@mellanox.com>
Mon, 11 Feb 2019 08:55:35 +0000 (10:55 +0200)
committerDavid S. Miller <davem@davemloft.net>
Tue, 12 Feb 2019 18:41:32 +0000 (13:41 -0500)
commit165f01354c52b6ce175b2c67f771c153f0563f41
tree2a967e039da5631027c1fbde1834356c5dbd1306
parent2cbfab07c69657a5a60323f86143f4ce8a829fa9
net: sched: protect block->chain0 with block->lock

In order to remove dependency on rtnl lock, use block->lock to protect
chain0 struct from concurrent modification. Rearrange code in chain0
callback add and del functions to only access chain0 when block->lock is
held.

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