summaryrefslogtreecommitdiff
path: root/include/net/rtnetlink.h
diff options
context:
space:
mode:
authorFlorian Westphal <fw@strlen.de>2017-12-02 23:44:05 +0300
committerDavid S. Miller <davem@davemloft.net>2017-12-04 19:32:22 +0300
commitaddf9b90de22f7aaad0db39bccb5d51ac47dd4e1 (patch)
treec503ab68da10306eae7170efb19dd614ba9cc93e /include/net/rtnetlink.h
parent9753c21f55d4ca2b02bbe81448f2a552ce79d068 (diff)
downloadlinux-addf9b90de22f7aaad0db39bccb5d51ac47dd4e1.tar.xz
net: rtnetlink: use rcu to free rtnl message handlers
rtnetlink is littered with READ_ONCE() because we can have read accesses while another cpu can write to the structure we're reading by (un)registering doit or dumpit handlers. This patch changes this so that (un)registering cpu allocates a new structure and then publishes it via rcu_assign_pointer, i.e. once another cpu can see such pointer no modifications will occur anymore. based on initial patch from Peter Zijlstra. Cc: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/rtnetlink.h')
0 files changed, 0 insertions, 0 deletions