diff options
author | Takashi Iwai <tiwai@suse.de> | 2017-01-25 22:11:17 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2017-01-25 22:11:17 +0100 |
commit | e1a063f43a5e0435ecf8a2b6d42e10e20e8caf61 (patch) | |
tree | 7329fb15e57917a503c859f7266fcd034728bd54 /kernel/pid_namespace.c | |
parent | ALSA: hda/realtek - Add support headphone Mic for ALC221 of HP platform (diff) | |
parent | ALSA: x86: hdmi: fix returnvar.cocci warnings (diff) | |
download | linux-e1a063f43a5e0435ecf8a2b6d42e10e20e8caf61.tar.xz linux-e1a063f43a5e0435ecf8a2b6d42e10e20e8caf61.zip |
Merge branch 'topic/intel-lpe-audio' into for-next
Diffstat (limited to 'kernel/pid_namespace.c')
-rw-r--r-- | kernel/pid_namespace.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/kernel/pid_namespace.c b/kernel/pid_namespace.c index df9e8e9e0be7..eef2ce968636 100644 --- a/kernel/pid_namespace.c +++ b/kernel/pid_namespace.c @@ -151,8 +151,12 @@ out: static void delayed_free_pidns(struct rcu_head *p) { - kmem_cache_free(pid_ns_cachep, - container_of(p, struct pid_namespace, rcu)); + struct pid_namespace *ns = container_of(p, struct pid_namespace, rcu); + + dec_pid_namespaces(ns->ucounts); + put_user_ns(ns->user_ns); + + kmem_cache_free(pid_ns_cachep, ns); } static void destroy_pid_namespace(struct pid_namespace *ns) @@ -162,8 +166,6 @@ static void destroy_pid_namespace(struct pid_namespace *ns) ns_free_inum(&ns->ns); for (i = 0; i < PIDMAP_ENTRIES; i++) kfree(ns->pidmap[i].page); - dec_pid_namespaces(ns->ucounts); - put_user_ns(ns->user_ns); call_rcu(&ns->rcu, delayed_free_pidns); } |