linux/ipc
Joe Korty b231cca438 message queues: increase range limits
Increase the range of various posix message queue limits.

Posix gives the message queue user the ability to 'trade off' the maximum
size of messages with the number of possible messages that can be 'in
flight'.  Linux currently makes this trade off more restrictive than it
needs to be.

In particular, the maximum message size today can be made no smaller than
8192.  This greatly restricts those applications that would like to have
the ability to post large numbers of very small messages.

So this task lowers the limit that the maximum message size can be set to,
from 8192 to 128.  It also lowers the limit that the maximum #number of
messages in flight can be set to, from 10 to 1.

With these changes the message queue user can make better trade offs
between #messages and message size, in order to get everything to fit
within the setrlimit(RLIMIT_MSGQUEUE) limit for that particular user.

This patch also applies the values in

	/proc/sys/fs/mqueue/msg_max
	/proc/sys/fs/mqueue/msgsize_max

as the defaults for the max #messages allowed and the max message size
allowed, respectively, for those applications that do not supply these.
Previously, the defaults were hardwired to 10 and 8192, respectively.

[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Joe Korty <joe.korty@ccur.com>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: Manfred Spraul <manfred@colorfullife.com>
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-10-20 08:52:40 -07:00
..
compat_mq.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
compat.c fix logic error in ipc compat semctl() 2007-07-06 10:23:43 -07:00
ipc_sysctl.c sysctl: simplify ->strategy 2008-10-16 11:21:47 -07:00
ipcns_notifier.c ipc: do not use a negative value to re-enable msgmni automatic recomputing 2008-07-25 10:53:42 -07:00
Makefile ipc: recompute msgmni on ipc namespace creation/removal 2008-04-29 08:06:12 -07:00
mqueue.c message queues: increase range limits 2008-10-20 08:52:40 -07:00
msg.c ipc: only output msgmni value at boot time 2008-06-06 11:29:12 -07:00
msgutil.c [PATCH] getting rid of all casts of k[cmz]alloc() calls 2006-12-13 09:05:58 -08:00
namespace.c ipc: recompute msgmni on ipc namespace creation/removal 2008-04-29 08:06:12 -07:00
sem.c ipc/sem.c: make free_un() static 2008-10-16 11:21:51 -07:00
shm.c SHM_LOCKED pages are unevictable 2008-10-20 08:50:26 -07:00
util.c ipc: get rid of ipc_lock_down() 2008-07-25 10:53:42 -07:00
util.h ipc: get rid of ipc_lock_down() 2008-07-25 10:53:42 -07:00