]> git.baikalelectronics.ru Git - kernel.git/commit
tipc: make link capability update thread safe
authorJon Maloy <jon.maloy@ericsson.com>
Wed, 18 Jul 2018 17:50:06 +0000 (19:50 +0200)
committerDavid S. Miller <davem@davemloft.net>
Fri, 20 Jul 2018 19:36:13 +0000 (12:36 -0700)
commit7f87735fdefc66a1bfc7dc41df8a1cd6287a4e36
tree5b5dac9106b60eb5d67e5f204a55ecaeb6db9b43
parentd1242d5fb97c97f8f353c04a218ba9419cea4559
tipc: make link capability update thread safe

The commit referred to below introduced an update of the link
capabilities field that is not safe. Given the recently added
feature to remove idle node and link items after 5 minutes, there
is a small risk that the update will happen at the very moment the
targeted link is being removed. To avoid this we have to perform
the update inside the node item's write lock protection.

Fixes: ca4c47585092 ("tipc: add sequence number check for link STATE messages")
Signed-off-by: Jon Maloy <jon.maloy@ericsson.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tipc/node.c