mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Willy Tarreau <willy@w.ods.org>
To: Marcelo Tosatti <marcelo@conectiva.com.br>
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH-2.4] make log buffer length selectable
Date: Tue, 26 Aug 2003 06:25:50 +0200	[thread overview]
Message-ID: <20030826042550.GJ734@alpha.home.local> (raw)
In-Reply-To: <200308251148.h7PBmU8B027700@hera.kernel.org>

On Mon, Aug 25, 2003 at 04:48:30AM -0700, Marcelo Tosatti wrote:
> final:
> 
> - 2.4.22-rc4 was released as 2.4.22 with no changes.

Hi Marcelo,

as you requested, here is the log_buf_len patch for inclusion in 23-pre.

Cheers,
Willy


diff -urN wt10-pre3/Documentation/Configure.help wt10-pre3-log-buf-len/Documentation/Configure.help
--- wt10-pre3/Documentation/Configure.help	Wed Mar 19 09:58:25 2003
+++ wt10-pre3-log-buf-len/Documentation/Configure.help	Tue Mar 25 08:20:35 2003
@@ -25231,6 +25231,19 @@
   output to the second serial port on these devices.  Saying N will
   cause the debug messages to appear on the first serial port.
 
+Kernel log buffer length shift
+CONFIG_LOG_BUF_SHIFT
+  The kernel log buffer has a fixed size of :
+      64 kB (2^16) on MULTIQUAD and IA64,
+     128 kB (2^17) on S390
+      32 kB (2^15) on SMP systems
+      16 kB (2^14) on UP systems
+
+  You have the ability to change this size with this paramter which
+  fixes the bit shift of to get the buffer length (which must be a
+  power of 2). Eg: a value of 16 sets the buffer to 64 kB (2^16).
+  The default value of 0 uses standard values above.
+
 Disable pgtable cache
 CONFIG_NO_PGT_CACHE
   Normally the kernel maintains a `quicklist' of preallocated
diff -urN wt10-pre3/arch/i386/config.in wt10-pre3-log-buf-len/arch/i386/config.in
--- wt10-pre3/arch/i386/config.in	Wed Mar 19 09:58:25 2003
+++ wt10-pre3-log-buf-len/arch/i386/config.in	Tue Mar 25 08:25:12 2003
@@ -508,6 +508,8 @@
     string '   Initial kernel command line' CONFIG_CMDLINE "root=301 ro"
 fi
 
+int 'Kernel messages buffer length shift (0 = default)' CONFIG_LOG_BUF_SHIFT 0
+
 endmenu
 
 source lib/Config.in
diff -urN wt10-pre3/kernel/printk.c wt10-pre3-log-buf-len/kernel/printk.c
--- wt10-pre3/kernel/printk.c	Wed Mar 19 09:58:20 2003
+++ wt10-pre3-log-buf-len/kernel/printk.c	Tue Mar 25 08:14:55 2003
@@ -29,6 +29,7 @@
 
 #include <asm/uaccess.h>
 
+#if !defined(CONFIG_LOG_BUF_SHIFT) || (CONFIG_LOG_BUF_SHIFT - 0 == 0)
 #if defined(CONFIG_MULTIQUAD) || defined(CONFIG_IA64)
 #define LOG_BUF_LEN	(65536)
 #elif defined(CONFIG_ARCH_S390)
@@ -37,6 +38,9 @@
 #define LOG_BUF_LEN	(32768)
 #else	
 #define LOG_BUF_LEN	(16384)			/* This must be a power of two */
+#endif
+#else /* CONFIG_LOG_BUF_SHIFT */
+#define LOG_BUF_LEN (1 << CONFIG_LOG_BUF_SHIFT)
 #endif
 
 #define LOG_BUF_MASK	(LOG_BUF_LEN-1)

  parent reply	other threads:[~2003-08-26  4:30 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-08-25 11:48 linux-2.4.22 released Marcelo Tosatti
2003-08-25  8:11 ` Enrico Demarin
2003-08-25 13:23 ` Matthias Andree
2003-08-25 13:32   ` Christoph Hellwig
2003-08-25 13:35   ` Ramón Rey Vicente󮠒
2003-08-25 21:13     ` J.A. Magallon
2003-08-25 22:22       ` Adrian Bunk
2003-08-26  0:21         ` Ramón Rey Vicente󮠒
2003-08-26 21:49           ` Diego Calleja García
2003-08-26 21:55             ` Adrian Bunk
2003-08-26 22:29               ` Diego Calleja García
2003-08-27  2:15                 ` Ramón Rey Vicente󮠒
2003-08-27  5:21                   ` Gerardo Exequiel Pozzi
2003-08-27  1:20               ` Chuck Campbell
2003-08-27  1:48                 ` David van Hoose
2003-08-27  1:55               ` David van Hoose
2003-08-27  3:28                 ` Kurt Wall
2003-08-27  2:01               ` Ramón Rey Vicente󮠒
2003-08-27  4:12               ` Willy Tarreau
2003-08-26 22:29             ` Matthias Andree
2003-08-27  9:47         ` Bas Mevissen
2003-08-26 13:55     ` Matthias Andree
2003-08-25 13:38   ` Nick Piggin
2003-08-25 22:34     ` Bill Davidsen
2003-08-25 14:38   ` Yann Droneaud
2003-08-25 15:35   ` Krzysztof Halasa
2003-08-25 16:03   ` Luca Montecchiani
2003-08-25 19:18     ` Erik Andersen
2003-08-25 20:00   ` Edesio Costa e Silva
2003-08-25 20:10   ` Tom Rini
2003-08-26 13:19   ` Rene Rebe
2003-08-26 15:00     ` Alan Cox
2003-08-27  3:47       ` CaT
2003-08-26 16:11     ` Willy Tarreau
2003-08-26 19:32     ` Greg KH
2003-08-26  1:52 ` cryptoapi doesn't build Tom Vier
2003-08-26 10:23   ` James Morris
2003-08-27 21:49     ` Tom Vier
2003-08-27 22:03     ` Marc-Christian Petersen
2003-08-26  4:25 ` Willy Tarreau [this message]
2003-08-27 20:09   ` [PATCH-2.4] make log buffer length selectable Tom Rini
2003-08-27 20:48     ` Willy Tarreau

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=20030826042550.GJ734@alpha.home.local \
    --to=willy@w.ods.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marcelo@conectiva.com.br \
    /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

Powered by JetHome