summaryrefslogtreecommitdiffstats
path: root/net/core/net_namespace.c
diff options
context:
space:
mode:
authorxiao jin <jin.xiao@intel.com>2014-04-25 08:50:54 +0800
committerDavid S. Miller <davem@davemloft.net>2014-04-26 12:50:23 -0400
commit1818ce4dc59a71a53faa33a7ca050ca9c406bf66 (patch)
treef1674c0ebbc83a29942dea9dde81260fd31b7b06 /net/core/net_namespace.c
parent98a20b735bb4ba5d97d35cf69eb0d8a2ee505de2 (diff)
downloadlinux-1818ce4dc59a71a53faa33a7ca050ca9c406bf66.tar.bz2
net_namespace: trivial cleanup
Do not initialize net_kill_list twice. list_replace_init() already takes care of initializing net_kill_list. We don't need to initialize it with LIST_HEAD() beforehand. Signed-off-by: xiao jin <jin.xiao@intel.com> Reviewed-by: David Cohen <david.a.cohen@linux.intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core/net_namespace.c')
-rw-r--r--net/core/net_namespace.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/core/net_namespace.c b/net/core/net_namespace.c
index 81d3a9a08453..05e949d48204 100644
--- a/net/core/net_namespace.c
+++ b/net/core/net_namespace.c
@@ -273,7 +273,7 @@ static void cleanup_net(struct work_struct *work)
{
const struct pernet_operations *ops;
struct net *net, *tmp;
- LIST_HEAD(net_kill_list);
+ struct list_head net_kill_list;
LIST_HEAD(net_exit_list);
/* Atomically snapshot the list of namespaces to cleanup */