Re: [PATCH 1/1] kernel/pid.c: Masking the flag out to get the actual value.

From: Eric W. Biederman
Date: Tue Jun 11 2013 - 21:54:41 EST

Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> writes:

> On Tue, 11 Jun 2013 18:16:50 -0700 ebiederm@xxxxxxxxxxxx (Eric W. Biederman) wrote:
>> > Hopefully we can fix this one by adding the missing comment.
>> Perhaps we can fix this one by having people who care read the code and
>> think about what it means?
> As is obvious from this thread, that approach isn't working.
>> Seriously if we are adding pids/processes in
>> the pid namespace why would to clean up the pid namespace?
> A good way to communicate the design would be to describe the semantics
> of PIDNS_HASH_ADDING, at its definition site.
> [idly wonders what the heck pid_namespace.level and pid.level do,
> sigh]

Explaining the semantics a bit more seems reasonable.

Something like:

unsigned int level; /* How deeply nested is this pid namespace */

#define PIDNS_HASH_ADDING (1U << 31) /* Process are still entering the pid namespace */

Sorry I don't have the focus to make that into a proper patch.


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at