]> git.baikalelectronics.ru Git - kernel.git/commit
lwtunnel: Add destroy state operation
authorTom Herbert <tom@herbertland.com>
Fri, 14 Oct 2016 18:25:36 +0000 (11:25 -0700)
committerDavid S. Miller <davem@davemloft.net>
Sat, 15 Oct 2016 21:33:41 +0000 (17:33 -0400)
commit258fd80f213a8c021571e182f56b39e510778310
tree3541ac4778bb5286fb77c7eed4c9ac914fd96ad4
parent2d85d870d8c06b6d037e02a7749a6ef8106c71ff
lwtunnel: Add destroy state operation

Users of lwt tunnels may set up some secondary state in build_state
function. Add a corresponding destroy_state function to allow users to
clean up state. This destroy state function is called from lwstate_free.
Also, we now free lwstate using kfree_rcu so user can assume structure
is not freed before rcu.

Acked-by: Roopa Prabhu <roopa@cumulusnetworks.com>
Signed-off-by: Tom Herbert <tom@herbertland.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/lwtunnel.h
net/core/lwtunnel.c