Skip to content

Commit 2d57792

Browse files
Rtoaxakpm00
authored andcommitted
pid: pid_ns_ctl_handler: remove useless comment
commit 95846ec("pid: replace pid bitmap implementation with IDR API") removes 'last_pid' element, and use the idr_get_cursor-idr_set_cursor pair to set the value of idr, so useless comments should be removed. Link: https://lkml.kernel.org/r/[email protected] Signed-off-by: Rong Tao <[email protected]> Cc: Aleksa Sarai <[email protected]> Cc: Christian Brauner <[email protected]> Cc: Frederic Weisbecker <[email protected]> Cc: Jeff Xu <[email protected]> Cc: Kees Cook <[email protected]> Cc: Luis Chamberlain <[email protected]> Signed-off-by: Andrew Morton <[email protected]>
1 parent 5e57418 commit 2d57792

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

kernel/pid_namespace.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -286,12 +286,6 @@ static int pid_ns_ctl_handler(struct ctl_table *table, int write,
286286
if (write && !checkpoint_restore_ns_capable(pid_ns->user_ns))
287287
return -EPERM;
288288

289-
/*
290-
* Writing directly to ns' last_pid field is OK, since this field
291-
* is volatile in a living namespace anyway and a code writing to
292-
* it should synchronize its usage with external means.
293-
*/
294-
295289
next = idr_get_cursor(&pid_ns->idr) - 1;
296290

297291
tmp.data = &next;

0 commit comments

Comments
 (0)