[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20130908180137.GA4915@redhat.com>
Date: Sun, 8 Sep 2013 20:01:37 +0200
From: Oleg Nesterov <oleg@...hat.com>
To: "Eric W. Biederman" <ebiederm@...ssion.com>
Cc: "Serge E. Hallyn" <serge@...lyn.com>,
Serge Hallyn <serge.hallyn@...ntu.com>,
linux-kernel@...r.kernel.org
Subject: free_pid() && PIDNS_HASH_ADDING
On 09/08, Oleg Nesterov wrote:
>
> Off topic. What if the first alloc_pid() succeeds and then later
> copy_process() fails. In this case free_pid() is called but
> PIDNS_HASH_ADDING was not cleared, we miss kern_unmount(), no?
Perhaps something like below?
Oleg.
--- x/kernel/pid.c
+++ x/kernel/pid.c
@@ -272,6 +272,8 @@ void free_pid(struct pid *pid)
*/
wake_up_process(ns->child_reaper);
break;
+ case PIDNS_HASH_ADDING:
+ WARN_ON(ns->child_reaper);
case 0:
schedule_work(&ns->proc_work);
break;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists