From 98f792f704928777ffe73ef2efb90fd07d576550 Mon Sep 17 00:00:00 2001 From: Michael Kerrisk Date: Thu, 29 Jan 2015 12:50:11 +0100 Subject: [PATCH] semop.2: Note defaults for SEMOPM and warn against increasing > 1000 Signed-off-by: Michael Kerrisk --- man2/semop.2 | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/man2/semop.2 b/man2/semop.2 index 357132c75..9c5482f82 100644 --- a/man2/semop.2 +++ b/man2/semop.2 @@ -459,10 +459,22 @@ call: .B SEMOPM Maximum number of operations allowed for one .BR semop () -call (32) -(on Linux, this limit can be read and modified via the third field of -.IR /proc/sys/kernel/sem ). +call. +Before Linux 3.19, +.\" commit e843e7d2c88b7db107a86bd2c7145dc715c058f4 +the default value for this limit was 32. +Since Linux 3.19, the default value is 500. +On Linux, this limit can be read and modified via the third field of +.IR /proc/sys/kernel/sem . .\" This /proc file is not available in Linux 2.2 and earlier -- MTK +.IR Note : +this limit should not be raised above 1000, +.\" See comment in Linux 3.19 source file include/uapi/linux/sem.h +because of the risk of that +.BR semop (2) +fails due to kernel memory fragmentation when allocating memory to copy the +.IR sops +array. .TP .B SEMVMX Maximum allowable value for