]> git.baikalelectronics.ru Git - kernel.git/commit
llc: Fix races between llc2 handler use and (un)registration
authorBen Hutchings <ben@decadent.org.uk>
Mon, 13 Aug 2012 02:50:55 +0000 (02:50 +0000)
committerDavid S. Miller <davem@davemloft.net>
Tue, 14 Aug 2012 23:52:02 +0000 (16:52 -0700)
commit18a52620204331d0736e31da959a79a294ecde04
tree8ad3aa78fdabdc1c60e5608b342ec1782eb72513
parent31389aab0cc831712da1a5def2fb7171e816e124
llc: Fix races between llc2 handler use and (un)registration

When registering the handlers, any state they rely on must be
completely initialised first.  When unregistering, we must wait until
they are definitely no longer running.  llc_rcv() must also avoid
reading the handler pointers again after checking for NULL.

Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/llc/llc_input.c
net/llc/llc_station.c