]> Git Repo - linux.git/commit
ipc: add sysctl to specify desired next object id
authorStanislav Kinsbursky <[email protected]>
Fri, 4 Jan 2013 23:34:50 +0000 (15:34 -0800)
committerLinus Torvalds <[email protected]>
Sat, 5 Jan 2013 00:11:45 +0000 (16:11 -0800)
commit03f595668017f1a1fb971c02fc37140bc6e7bb1c
tree3aa5c4b32b5fd396f0d74679548de8c09ca195a1
parent9afdacda0252fc1ddb7907728e878518edbcdfce
ipc: add sysctl to specify desired next object id

Add 3 new variables and sysctls to tune them (by one "next_id" variable
for messages, semaphores and shared memory respectively).  This variable
can be used to set desired id for next allocated IPC object.  By default
it's equal to -1 and old behaviour is preserved.  If this variable is
non-negative, then desired idr will be extracted from it and used as a
start value to search for free IDR slot.

Notes:

1) this patch doesn't guarantee that the new object will have desired
   id.  So it's up to user space how to handle new object with wrong id.

2) After a sucessful id allocation attempt, "next_id" will be set back
   to -1 (if it was non-negative).

[[email protected]: checkpatch fixes]
Signed-off-by: Stanislav Kinsbursky <[email protected]>
Cc: Serge Hallyn <[email protected]>
Cc: "Eric W. Biederman" <[email protected]>
Cc: Pavel Emelyanov <[email protected]>
Cc: Al Viro <[email protected]>
Cc: KOSAKI Motohiro <[email protected]>
Cc: Michael Kerrisk <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Documentation/sysctl/kernel.txt
include/linux/ipc_namespace.h
ipc/ipc_sysctl.c
ipc/util.c
ipc/util.h
This page took 0.063614 seconds and 4 git commands to generate.