Skip to content

Commit 4112be7

Browse files
vaverinamschuma-ntap
authored andcommitted
sunrpc: exit_net cleanup check added
Be sure that all_clients list initialized in net_init hook was return to initial state. Signed-off-by: Vasily Averin <vvs@virtuozzo.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
1 parent b0b5352 commit 4112be7

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

net/sunrpc/sunrpc_syms.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,10 +65,13 @@ static __net_init int sunrpc_init_net(struct net *net)
6565

6666
static __net_exit void sunrpc_exit_net(struct net *net)
6767
{
68+
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
69+
6870
rpc_pipefs_exit_net(net);
6971
unix_gid_cache_destroy(net);
7072
ip_map_cache_destroy(net);
7173
rpc_proc_exit(net);
74+
WARN_ON_ONCE(!list_empty(&sn->all_clients));
7275
}
7376

7477
static struct pernet_operations sunrpc_net_ops = {

0 commit comments

Comments
 (0)