]> git.baikalelectronics.ru Git - kernel.git/commit
Merge branch 'lwt-module-unload'
authorDavid S. Miller <davem@davemloft.net>
Tue, 24 Jan 2017 21:21:37 +0000 (16:21 -0500)
committerDavid S. Miller <davem@davemloft.net>
Tue, 24 Jan 2017 21:21:37 +0000 (16:21 -0500)
commit1e08591b3975dc37b80b9c82cb31077ccbdd559a
treec9c7eb5576834cae05dba40e82ca84a7772b7a51
parentc06c75879741f6617923481a9873a269ade9c4d4
parent9d42a504f30055ea59cd9cdebe98a650733e4ecd
Merge branch 'lwt-module-unload'

Robert Shearman says:

====================
net: Fix oops on state free after lwt module unload

An oops is seen in lwtstate_free after an lwt ops module has been
unloaded. This patchset fixes this by preventing modules implementing
lwtunnel ops from being unloaded whilst there's state alive using
those ops. The first patch adds fills in a new owner field in all lwt
ops and the second patch makes use of this to reference count the
modules as state is built and destroyed using them.

Changes in v3:
 - don't put module reference if try_module_get fails on building state

Changes in v2:
 - specify module owner for all modules as suggested by DaveM
 - reference count all modules building lwt state, not just those ops
   implementing destroy_state, as also suggested by DaveM.
 - rebased on top of David Ahern's lwtunnel changes
====================

Signed-off-by: David S. Miller <davem@davemloft.net>