public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Nadia.Derbey@bull.net
To: akpm@linux-foundation.org
Cc: mtk.manpages@googlemail.com, linux-kernel@vger.kernel.org,
	Nadia Derbey <Nadia.Derbey@bull.net>
Subject: [PATCH] Restore MSGPOOL original value
Date: Mon, 26 May 2008 11:17:17 +0200	[thread overview]
Message-ID: <20080526091741.735792000@bull.net> (raw)
In-Reply-To: 20080526091716.087875000@bull.net

[-- Attachment #1: restore_msgpool_original_value.patch --]
[-- Type: text/plain, Size: 1602 bytes --]

Hi,

When posting:
[PATCH 1/8] Scaling msgmni to the amount of lowmem
(see http://article.gmane.org/gmane.linux.kernel/637849/), I have changed the
MSGPOOL value to make it fit what is said in the man pages (i.e. a size in
bytes).

But Michael Kerrisk rightly complained that this change could affect the ABI.
So I'm posting this patch to make MSGPOOL expressed back in Kbytes.
Michael, on his side, has fixed the man page.

This patch applies to 2.6.26-rc2-mm1.

Signed-off-by: Nadia Derbey <Nadia.Derbey@bull.net>

---
 include/linux/msg.h |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Index: linux-2.6.26-rc2-mm1/include/linux/msg.h
===================================================================
--- linux-2.6.26-rc2-mm1.orig/include/linux/msg.h	2008-05-26 11:06:53.000000000 +0200
+++ linux-2.6.26-rc2-mm1/include/linux/msg.h	2008-05-26 11:18:34.000000000 +0200
@@ -64,11 +64,11 @@ struct msginfo {
 #define MSGMNB 16384   /* <= INT_MAX */   /* default max size of a message queue */
 
 /* unused */
-#define MSGPOOL (MSGMNI * MSGMNB) /* size in bytes of message pool */
+#define MSGPOOL (MSGMNI * MSGMNB / 1024) /* size in kbytes of message pool */
 #define MSGTQL  MSGMNB            /* number of system message headers */
 #define MSGMAP  MSGMNB            /* number of entries in message map */
 #define MSGSSZ  16                /* message segment size */
-#define __MSGSEG (MSGPOOL / MSGSSZ) /* max no. of segments */
+#define __MSGSEG ((MSGPOOL * 1024) / MSGSSZ) /* max no. of segments */
 #define MSGSEG (__MSGSEG <= 0xffff ? __MSGSEG : 0xffff)
 
 #ifdef __KERNEL__

--

       reply	other threads:[~2008-05-26  9:17 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20080526091716.087875000@bull.net>
2008-05-26  9:17 ` Nadia.Derbey [this message]
2008-05-26 10:38   ` [PATCH] Restore MSGPOOL original value Michael Kerrisk
2008-05-28 22:48   ` Andrew Morton
2008-05-29 10:01     ` Nadia Derbey

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20080526091741.735792000@bull.net \
    --to=nadia.derbey@bull.net \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mtk.manpages@googlemail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox