diff options
author | Vlad Buslov <vladbu@mellanox.com> | 2019-03-21 15:17:41 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-03-21 14:32:17 -0700 |
commit | 272ffaadeb3e739baa70aef7e92ad844b62b3304 (patch) | |
tree | f513dd4df2cd39594bb93390b309f7a04d8322ee /net/Makefile | |
parent | 9a2d93899897efb0702f97e71387f9d0ae94a9d5 (diff) | |
download | linux-272ffaadeb3e739baa70aef7e92ad844b62b3304.tar.bz2 |
net: sched: flower: handle concurrent tcf proto deletion
Without rtnl lock protection tcf proto can be deleted concurrently. Check
tcf proto 'deleting' flag after taking tcf spinlock to verify that no
concurrent deletion is in progress. Return EAGAIN error if concurrent
deletion detected, which will cause caller to retry and possibly create new
instance of tcf proto.
Retry mechanism is a result of fine-grained locking approach used in this
and previous changes in series and is necessary to allow concurrent updates
on same chain instance. Alternative approach would be to lock the whole
chain while updating filters on any of child tp's, adding and removing
classifier instances from the chain. However, since most CPU-intensive
parts of filter update code are specifically in classifier code and its
dependencies (extensions and hw offloads), such approach would negate most
of the gains introduced by this change and previous changes in the series
when updating same chain instance.
Signed-off-by: Vlad Buslov <vladbu@mellanox.com>
Reviewed-by: Stefano Brivio <sbrivio@redhat.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/Makefile')
0 files changed, 0 insertions, 0 deletions