Files
kernel/include/linux
Pierre Peiffer ed2ddbf88c IPC: make struct ipc_ids static in ipc_namespace
Each ipc_namespace contains a table of 3 pointers to struct ipc_ids (3 for
msg, sem and shm, structure used to store all ipcs) These 'struct ipc_ids'
are dynamically allocated for each icp_namespace as the ipc_namespace
itself (for the init namespace, they are initialized with pointers to
static variables instead)

It is so for historical reason: in fact, before the use of idr to store the
ipcs, the ipcs were stored in tables of variable length, depending of the
maximum number of ipc allowed.  Now, these 'struct ipc_ids' have a fixed
size.  As they are allocated in any cases for each new ipc_namespace, there
is no gain of memory in having them allocated separately of the struct
ipc_namespace.

This patch proposes to make this table static in the struct ipc_namespace.
Thus, we can allocate all in once and get rid of all the code needed to
allocate and free these ipc_ids separately.

Signed-off-by: Pierre Peiffer <pierre.peiffer@bull.net>
Acked-by: Cedric Le Goater <clg@fr.ibm.com>
Cc: Pavel Emelyanov <xemul@openvz.org>
Cc: Nadia Derbey <Nadia.Derbey@bull.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-08 09:22:26 -08:00
..
2008-02-06 10:41:15 -08:00
2008-02-07 08:42:23 -08:00
2008-02-05 09:44:13 -08:00
2008-02-05 03:20:13 -08:00
2008-02-07 08:42:30 -08:00
2008-02-06 10:41:02 -08:00
2008-02-01 11:34:49 +01:00
2008-01-29 21:55:15 +01:00
2008-02-03 17:45:46 +02:00
2008-01-30 13:31:10 +01:00
2008-02-03 17:45:46 +02:00
2008-02-03 15:42:53 +02:00
2008-02-08 02:09:56 +00:00
2008-02-08 09:22:24 -08:00
2008-02-07 20:39:40 -05:00
2008-02-07 08:42:30 -08:00
2008-02-03 17:45:46 +02:00
2008-02-03 15:42:53 +02:00
2008-02-05 09:44:19 -08:00
2008-01-30 13:30:27 +01:00
2008-02-07 20:39:44 -05:00
2008-02-06 02:57:51 +01:00
2008-02-01 16:13:16 -05:00
2008-01-28 15:08:27 -08:00
2008-02-06 22:39:45 +01:00
2008-02-06 10:41:02 -08:00
2008-01-31 19:28:20 -08:00
2008-01-28 23:58:27 -05:00
2008-02-06 10:41:21 -08:00
2008-02-07 08:42:30 -08:00
2008-01-30 13:33:13 +01:00
2008-02-03 17:45:46 +02:00
2008-02-06 10:41:01 -08:00
2008-02-05 09:44:16 -08:00
2008-01-30 02:06:08 -05:00
2008-02-06 16:29:59 +11:00
2008-02-05 09:44:19 -08:00
2008-02-02 11:32:01 -08:00
2008-02-02 02:44:34 +03:00
2008-02-03 17:45:46 +02:00
2008-02-06 10:41:20 -08:00
2008-02-06 10:41:07 -08:00
2008-02-05 09:44:22 -08:00
2008-01-30 13:31:47 +01:00
2008-01-31 19:26:46 -08:00
2008-02-07 08:42:18 -08:00
2008-02-07 08:42:34 -08:00
2008-02-07 08:42:30 -08:00
2008-02-06 10:41:02 -08:00
2008-02-03 17:45:46 +02:00
2008-01-31 19:28:30 -08:00
2008-01-30 13:31:20 +01:00
2008-01-30 13:31:20 +01:00
2008-01-30 13:31:20 +01:00
2008-02-07 08:42:34 -08:00
2008-02-05 09:44:16 -08:00
2008-02-05 09:44:07 -08:00
2008-02-01 23:20:26 -05:00
2008-02-01 17:45:14 +01:00
2008-02-06 10:41:02 -08:00
2008-02-07 08:42:16 -08:00
2008-02-04 23:50:13 +11:00
2008-02-04 23:50:03 +11:00
2008-02-04 23:50:02 +11:00
2008-02-04 23:50:03 +11:00
2008-02-06 10:41:03 -08:00
2008-02-05 09:44:07 -08:00
2008-02-03 15:42:53 +02:00