* [PATCH] configurable LOG_BUF_SIZE @ 2003-01-02 23:09 Randy.Dunlap 2003-01-06 18:50 ` Tom Rini 0 siblings, 1 reply; 18+ messages in thread From: Randy.Dunlap @ 2003-01-02 23:09 UTC (permalink / raw) To: linux-kernel; +Cc: torvalds Hi, This patch to 2.5.54 make LOG_BUF_LEN a configurable option. Actually its shift value is configurable, and that keeps it a power of 2. Please apply. Thanks, -- ~Randy patch_name: logbuf-config-2554.patch patch_version: 2003.01.02 author: Randy Dunlap <rddunlap@osdl.org> description: change LOG_BUF_LEN to a config option (LOG_BUF_SHIFT) product: linux product_versions: 2.5.54 changelog: (a) add in General Setup (b) use a SHIFT value (enforces power of 2, gives more choices) URL: http://www.osdl.org/archive/rddunlap/patches/ requires: kconfig in 2.5.52 or later conflicts: diffstat: init/Kconfig | 45 +++++++++++++++++++++++++++++++++++++++++++++ kernel/printk.c | 11 +---------- 2 files changed, 46 insertions(+), 10 deletions(-) --- ./kernel/printk.c%LOG Wed Jan 1 19:23:19 2003 +++ ./kernel/printk.c Thu Jan 2 14:48:59 2003 @@ -31,16 +31,7 @@ #include <asm/uaccess.h> -#if defined(CONFIG_X86_NUMAQ) || defined(CONFIG_IA64) -#define LOG_BUF_LEN (65536) -#elif defined(CONFIG_ARCH_S390) -#define LOG_BUF_LEN (131072) -#elif defined(CONFIG_SMP) -#define LOG_BUF_LEN (32768) -#else -#define LOG_BUF_LEN (16384) /* This must be a power of two */ -#endif - +#define LOG_BUF_LEN (1 << CONFIG_LOG_BUF_SHIFT) /* This must be a power of two */ #define LOG_BUF_MASK (LOG_BUF_LEN-1) /* printk's without a loglevel use this.. */ --- ./init/Kconfig%LOG Thu Jan 2 14:34:27 2003 +++ ./init/Kconfig Thu Jan 2 14:42:01 2003 @@ -98,6 +98,51 @@ building a kernel for install/rescue disks or your system is very limited in memory. +choice + prompt "Kernel log buffer size" + default LOG_BUF_SHIFT_17 if ARCH_S390 + default LOG_BUF_SHIFT_16 if X86_NUMAQ || IA64 + default LOG_BUF_SHIFT_15 if SMP + default LOG_BUF_SHIFT_14 + help + Select kernel log buffer size from this list (power of 2). + Defaults: 17 (=> 128 KB for S/390) + 16 (=> 64 KB for x86 NUMAQ or IA-64) + 15 (=> 32 KB for SMP) + 14 (=> 16 KB for uniprocessor) + +config LOG_BUF_SHIFT_17 + bool "128 KB" + default y if ARCH_S390 + +config LOG_BUF_SHIFT_16 + bool "64 KB" + default y if X86_NUMAQ || IA64 + +config LOG_BUF_SHIFT_15 + bool "32 KB" + default y if SMP + +config LOG_BUF_SHIFT_14 + bool "16 KB" + +config LOG_BUF_SHIFT_13 + bool "8 KB" + +config LOG_BUF_SHIFT_12 + bool "4 KB" + +endchoice + +config LOG_BUF_SHIFT + int + default 17 if LOG_BUF_SHIFT_17=y + default 16 if LOG_BUF_SHIFT_16=y + default 15 if LOG_BUF_SHIFT_15=y + default 14 if LOG_BUF_SHIFT_14=y + default 13 if LOG_BUF_SHIFT_13=y + default 12 if LOG_BUF_SHIFT_12=y + endmenu ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE 2003-01-02 23:09 [PATCH] configurable LOG_BUF_SIZE Randy.Dunlap @ 2003-01-06 18:50 ` Tom Rini 2003-01-06 18:57 ` Randy.Dunlap 0 siblings, 1 reply; 18+ messages in thread From: Tom Rini @ 2003-01-06 18:50 UTC (permalink / raw) To: Randy.Dunlap; +Cc: linux-kernel, torvalds On Thu, Jan 02, 2003 at 03:09:17PM -0800, Randy.Dunlap wrote: > This patch to 2.5.54 make LOG_BUF_LEN a configurable option. > Actually its shift value is configurable, and that keeps it > a power of 2. Erm, why not just prompt for an int, slightly change the help wording, and then just give a default int value directly. Flexibility is good for everyone. -- Tom Rini (TR1265) http://gate.crashing.org/~trini/ ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE 2003-01-06 18:50 ` Tom Rini @ 2003-01-06 18:57 ` Randy.Dunlap 2003-01-06 19:06 ` Tom Rini 0 siblings, 1 reply; 18+ messages in thread From: Randy.Dunlap @ 2003-01-06 18:57 UTC (permalink / raw) To: Tom Rini; +Cc: linux-kernel, torvalds On Mon, 6 Jan 2003, Tom Rini wrote: | On Thu, Jan 02, 2003 at 03:09:17PM -0800, Randy.Dunlap wrote: | | > This patch to 2.5.54 make LOG_BUF_LEN a configurable option. | > Actually its shift value is configurable, and that keeps it | > a power of 2. | | Erm, why not just prompt for an int, slightly change the help wording, | and then just give a default int value directly. | | Flexibility is good for everyone. Sure, I like that, but LOG_BUF_LEN must be a power of 2 (currently) and I was trying not to rewrite that circular buffer code, that's all. However, I will if that's desirable. And kconfig doesn't have a way to enforce the selected value... I asked Roman about 2-3 weeks ago about some way to enforce ranges on config values, e.g. (but that wouldn't affect powers of 2). Linus also told me that he's not crazy about this change. I just want the LOG_BUF_LEN available outside of kernel/printk.c... -- ~Randy ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE 2003-01-06 18:57 ` Randy.Dunlap @ 2003-01-06 19:06 ` Tom Rini 2003-01-06 19:05 ` Randy.Dunlap 2003-01-06 19:16 ` Linus Torvalds 0 siblings, 2 replies; 18+ messages in thread From: Tom Rini @ 2003-01-06 19:06 UTC (permalink / raw) To: Randy.Dunlap; +Cc: linux-kernel, torvalds On Mon, Jan 06, 2003 at 10:57:01AM -0800, Randy.Dunlap wrote: > On Mon, 6 Jan 2003, Tom Rini wrote: > > | On Thu, Jan 02, 2003 at 03:09:17PM -0800, Randy.Dunlap wrote: > | > | > This patch to 2.5.54 make LOG_BUF_LEN a configurable option. > | > Actually its shift value is configurable, and that keeps it > | > a power of 2. > | > | Erm, why not just prompt for an int, slightly change the help wording, > | and then just give a default int value directly. > | > | Flexibility is good for everyone. > > Sure, I like that, but LOG_BUF_LEN must be a power of 2 (currently) > and I was trying not to rewrite that circular buffer code, that's all. > However, I will if that's desirable. I actually meant prompting for the shift value itself. > And kconfig doesn't have a way to enforce the selected value... That is a shame, I've had to resort to doing checks like that at compile time for that reason. > Linus also told me that he's not crazy about this change. Maybe he would be, if it was cleaner than the current code in the end. :) -- Tom Rini (TR1265) http://gate.crashing.org/~trini/ ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE 2003-01-06 19:06 ` Tom Rini @ 2003-01-06 19:05 ` Randy.Dunlap 2003-01-06 19:15 ` Tom Rini 2003-01-06 19:16 ` Linus Torvalds 1 sibling, 1 reply; 18+ messages in thread From: Randy.Dunlap @ 2003-01-06 19:05 UTC (permalink / raw) To: Tom Rini; +Cc: linux-kernel, torvalds On Mon, 6 Jan 2003, Tom Rini wrote: | On Mon, Jan 06, 2003 at 10:57:01AM -0800, Randy.Dunlap wrote: | > On Mon, 6 Jan 2003, Tom Rini wrote: | > | > | On Thu, Jan 02, 2003 at 03:09:17PM -0800, Randy.Dunlap wrote: | > | | > | > This patch to 2.5.54 make LOG_BUF_LEN a configurable option. | > | > Actually its shift value is configurable, and that keeps it | > | > a power of 2. | > | | > | Erm, why not just prompt for an int, slightly change the help wording, | > | and then just give a default int value directly. | > | | > | Flexibility is good for everyone. | > | > Sure, I like that, but LOG_BUF_LEN must be a power of 2 (currently) | > and I was trying not to rewrite that circular buffer code, that's all. | > However, I will if that's desirable. | | I actually meant prompting for the shift value itself. I did think of that, but it's too user-unfriendly IMO. Heck, it's even developer-unfriendly IMO. | > And kconfig doesn't have a way to enforce the selected value... | | That is a shame, I've had to resort to doing checks like that at compile | time for that reason. | | > Linus also told me that he's not crazy about this change. | | Maybe he would be, if it was cleaner than the current code in the end. | :) -- ~Randy ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE 2003-01-06 19:05 ` Randy.Dunlap @ 2003-01-06 19:15 ` Tom Rini 0 siblings, 0 replies; 18+ messages in thread From: Tom Rini @ 2003-01-06 19:15 UTC (permalink / raw) To: Randy.Dunlap; +Cc: linux-kernel, torvalds On Mon, Jan 06, 2003 at 11:05:49AM -0800, Randy.Dunlap wrote: > On Mon, 6 Jan 2003, Tom Rini wrote: > > | On Mon, Jan 06, 2003 at 10:57:01AM -0800, Randy.Dunlap wrote: > | > On Mon, 6 Jan 2003, Tom Rini wrote: > | > > | > | On Thu, Jan 02, 2003 at 03:09:17PM -0800, Randy.Dunlap wrote: > | > | > | > | > This patch to 2.5.54 make LOG_BUF_LEN a configurable option. > | > | > Actually its shift value is configurable, and that keeps it > | > | > a power of 2. > | > | > | > | Erm, why not just prompt for an int, slightly change the help wording, > | > | and then just give a default int value directly. > | > | > | > | Flexibility is good for everyone. > | > > | > Sure, I like that, but LOG_BUF_LEN must be a power of 2 (currently) > | > and I was trying not to rewrite that circular buffer code, that's all. > | > However, I will if that's desirable. > | > | I actually meant prompting for the shift value itself. > > I did think of that, but it's too user-unfriendly IMO. > Heck, it's even developer-unfriendly IMO. I don't see how it's any worse than giving them a choice of 3-4 preset values. Especially with the current defaults being given as the if-in-doubt option :) This is would also be a good reason to have a CONFIG_ADVANCED_OPTIONS globally, ala what's in arch/ppc/Kconfig now. If selected, you can pick some 'user-unfriendly' options, and otherwise a default is picked for you. This is also a good argument for the TWEAKS stuff I talked about a while ago, but haven't found the time yet to finish the dependancy stuff (it works ala CONFIG stuff now, _except_ for a new TWEAK key). -- Tom Rini (TR1265) http://gate.crashing.org/~trini/ ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE 2003-01-06 19:06 ` Tom Rini 2003-01-06 19:05 ` Randy.Dunlap @ 2003-01-06 19:16 ` Linus Torvalds 2003-01-06 19:20 ` Randy.Dunlap 1 sibling, 1 reply; 18+ messages in thread From: Linus Torvalds @ 2003-01-06 19:16 UTC (permalink / raw) To: Tom Rini; +Cc: Randy.Dunlap, linux-kernel On Mon, 6 Jan 2003, Tom Rini wrote: > > > Linus also told me that he's not crazy about this change. > > Maybe he would be, if it was cleaner than the current code in the end. > :) No, the reason I'm not crazy about it is that I simply _hate_ having too many user knobs to tweak. I don't like tweaking like that, it's just disturbing. I'd probably be happier if the current one didn't even _ask_ the user (or only asked the user if kernel debugging is enabled), and just silently defaulted to the normal values. Linus ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE 2003-01-06 19:16 ` Linus Torvalds @ 2003-01-06 19:20 ` Randy.Dunlap 2003-01-06 21:06 ` Randy.Dunlap 0 siblings, 1 reply; 18+ messages in thread From: Randy.Dunlap @ 2003-01-06 19:20 UTC (permalink / raw) To: Linus Torvalds; +Cc: Tom Rini, linux-kernel On Mon, 6 Jan 2003, Linus Torvalds wrote: | | On Mon, 6 Jan 2003, Tom Rini wrote: | > | > > Linus also told me that he's not crazy about this change. | > | > Maybe he would be, if it was cleaner than the current code in the end. | > :) | | No, the reason I'm not crazy about it is that I simply _hate_ having too | many user knobs to tweak. I don't like tweaking like that, it's just | disturbing. | | I'd probably be happier if the current one didn't even _ask_ the user (or | only asked the user if kernel debugging is enabled), and just silently | defaulted to the normal values. I'll be happy to move it there (later today)... -- ~Randy ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE 2003-01-06 19:20 ` Randy.Dunlap @ 2003-01-06 21:06 ` Randy.Dunlap 2003-01-06 21:26 ` Tomas Szepe ` (2 more replies) 0 siblings, 3 replies; 18+ messages in thread From: Randy.Dunlap @ 2003-01-06 21:06 UTC (permalink / raw) To: Linus Torvalds; +Cc: Tom Rini, linux-kernel, zippel, Sam Ravnborg, szepe On Mon, 6 Jan 2003, Randy.Dunlap wrote: | On Mon, 6 Jan 2003, Linus Torvalds wrote: | | | | | On Mon, 6 Jan 2003, Tom Rini wrote: | | > | | > > Linus also told me that he's not crazy about this change. | | > | | > Maybe he would be, if it was cleaner than the current code in the end. | | > :) | | | | No, the reason I'm not crazy about it is that I simply _hate_ having too | | many user knobs to tweak. I don't like tweaking like that, it's just | | disturbing. | |--------------------------------------------------------------------------- | | I'd probably be happier if the current one didn't even _ask_ the user (or| | | only asked the user if kernel debugging is enabled), and just silently | | | defaulted to the normal values. | | |--------------------------------------------------------------------------- | | I'll be happy to move it there (later today)... Hm. Roman, Tomas, Sam- Do any of you know how to write a kconfig item like Linus described above (in the box)? It's simple enough to have a config option that isn't available if DEBUG_KERNEL is false, but how do I make default values for it when it's false? The config option must still exist in this case, but not be presented to the user as a choice. My attempt (for i386) is attached. Applies to 2.5.54 + yesterday's patch. Are there better ways to do this? Thanks, -- ~Randy --- ./arch/i386/Kconfig%LGBUF Wed Jan 1 19:21:10 2003 +++ ./arch/i386/Kconfig Mon Jan 6 12:37:54 2003 @@ -1624,6 +1624,31 @@ If you don't debug the kernel, you can say N, but we may not be able to solve problems without frame pointers. +config LOG_BUF_SHIFT + int "Kernel log buffer size" + depends on DEBUG_KERNEL + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 (=> 128 KB for S/390) + 16 (=> 64 KB for x86 NUMAQ or IA-64) + 15 (=> 32 KB for SMP) + 14 (=> 16 KB for uniprocessor) + 13 (=> 8 KB) + 12 (=> 4 KB) + +config LOG_BUF_SHIFT + int + depends on !DEBUG_KERNEL + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + config X86_EXTRA_IRQS bool depends on X86_LOCAL_APIC || X86_VOYAGER --- ./init/Kconfig%LGBUF Mon Jan 6 11:52:14 2003 +++ ./init/Kconfig Mon Jan 6 11:55:00 2003 @@ -98,51 +98,6 @@ building a kernel for install/rescue disks or your system is very limited in memory. -choice - prompt "Kernel log buffer size" - default LOG_BUF_SHIFT_17 if ARCH_S390 - default LOG_BUF_SHIFT_16 if X86_NUMAQ || IA64 - default LOG_BUF_SHIFT_15 if SMP - default LOG_BUF_SHIFT_14 - help - Select kernel log buffer size from this list (power of 2). - Defaults: 17 (=> 128 KB for S/390) - 16 (=> 64 KB for x86 NUMAQ or IA-64) - 15 (=> 32 KB for SMP) - 14 (=> 16 KB for uniprocessor) - -config LOG_BUF_SHIFT_17 - bool "128 KB" - default y if ARCH_S390 - -config LOG_BUF_SHIFT_16 - bool "64 KB" - default y if X86_NUMAQ || IA64 - -config LOG_BUF_SHIFT_15 - bool "32 KB" - default y if SMP - -config LOG_BUF_SHIFT_14 - bool "16 KB" - -config LOG_BUF_SHIFT_13 - bool "8 KB" - -config LOG_BUF_SHIFT_12 - bool "4 KB" - -endchoice - -config LOG_BUF_SHIFT - int - default 17 if LOG_BUF_SHIFT_17=y - default 16 if LOG_BUF_SHIFT_16=y - default 15 if LOG_BUF_SHIFT_15=y - default 14 if LOG_BUF_SHIFT_14=y - default 13 if LOG_BUF_SHIFT_13=y - default 12 if LOG_BUF_SHIFT_12=y - endmenu ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE 2003-01-06 21:06 ` Randy.Dunlap @ 2003-01-06 21:26 ` Tomas Szepe 2003-01-06 22:04 ` Randy.Dunlap 2003-01-06 23:30 ` [PATCH] configurable LOG_BUF_SIZE (updated) Randy.Dunlap 2003-01-07 0:12 ` [PATCH] configurable LOG_BUF_SIZE Roman Zippel 2 siblings, 1 reply; 18+ messages in thread From: Tomas Szepe @ 2003-01-06 21:26 UTC (permalink / raw) To: Randy.Dunlap; +Cc: Linus Torvalds, Tom Rini, linux-kernel, zippel, Sam Ravnborg > [rddunlap@osdl.org] > | |--------------------------------------------------------------------------- > | | I'd probably be happier if the current one didn't even _ask_ the user (or| > | | only asked the user if kernel debugging is enabled), and just silently | > | | defaulted to the normal values. | > | |--------------------------------------------------------------------------- > > Hm. Roman, Tomas, Sam- > > Do any of you know how to write a kconfig item like Linus described > above (in the box)? > > It's simple enough to have a config option that isn't available if > DEBUG_KERNEL is false, but how do I make default values for it > when it's false? > The config option must still exist in this case, but not be presented > to the user as a choice. > > [snip] > > +config LOG_BUF_SHIFT > + int "Kernel log buffer size" > + depends on DEBUG_KERNEL > + default 17 if ARCH_S390 > + default 16 if X86_NUMAQ || IA64 > + default 15 if SMP > + default 14 > + help > + Select kernel log buffer size as a power of 2. > + Defaults and Examples: > + 17 (=> 128 KB for S/390) > + 16 (=> 64 KB for x86 NUMAQ or IA-64) > + 15 (=> 32 KB for SMP) > + 14 (=> 16 KB for uniprocessor) > + 13 (=> 8 KB) > + 12 (=> 4 KB) > + > +config LOG_BUF_SHIFT > + int > + depends on !DEBUG_KERNEL > + default 17 if ARCH_S390 > + default 16 if X86_NUMAQ || IA64 > + default 15 if SMP > + default 14 > + Randy, this looks correct to me. Maybe using if/endif instead of the two 'depends on' would make the entry more explicit to the eye of a future beholder. -- Tomas Szepe <szepe@pinerecords.com> ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE 2003-01-06 21:26 ` Tomas Szepe @ 2003-01-06 22:04 ` Randy.Dunlap 2003-01-06 22:56 ` Tom Rini 0 siblings, 1 reply; 18+ messages in thread From: Randy.Dunlap @ 2003-01-06 22:04 UTC (permalink / raw) To: Tomas Szepe; +Cc: Linus Torvalds, Tom Rini, linux-kernel, zippel, Sam Ravnborg On Mon, 6 Jan 2003, Tomas Szepe wrote: | > [rddunlap@osdl.org] | | > | |--------------------------------------------------------------------------- | > | | I'd probably be happier if the current one didn't even _ask_ the user (or| | > | | only asked the user if kernel debugging is enabled), and just silently | | > | | defaulted to the normal values. | | > | |--------------------------------------------------------------------------- | > | Randy, | | this looks correct to me. Maybe using if/endif instead of the two | 'depends on' would make the entry more explicit to the eye of a future | beholder. Hey Tomas, Thanks for looking and giving me your comments. if/endif would be useful there, especially if there was also an 'else' available... -- ~Randy ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE 2003-01-06 22:04 ` Randy.Dunlap @ 2003-01-06 22:56 ` Tom Rini 0 siblings, 0 replies; 18+ messages in thread From: Tom Rini @ 2003-01-06 22:56 UTC (permalink / raw) To: Randy.Dunlap Cc: Tomas Szepe, Linus Torvalds, linux-kernel, zippel, Sam Ravnborg On Mon, Jan 06, 2003 at 02:04:52PM -0800, Randy.Dunlap wrote: > On Mon, 6 Jan 2003, Tomas Szepe wrote: > > | > [rddunlap@osdl.org] > | > | > | |--------------------------------------------------------------------------- > | > | | I'd probably be happier if the current one didn't even _ask_ the user (or| > | > | | only asked the user if kernel debugging is enabled), and just silently | > | > | | defaulted to the normal values. | > | > | |--------------------------------------------------------------------------- > | > > | Randy, > | > | this looks correct to me. Maybe using if/endif instead of the two > | 'depends on' would make the entry more explicit to the eye of a future > | beholder. > > Hey Tomas, > > Thanks for looking and giving me your comments. > > if/endif would be useful there, especially if there was also an 'else' > available... I think that's by design (if / else is limiting, which is why you have a very flexible depends syntax). That looks exactly like what we do in arch/ppc/Kconfig. Maybe a comment 'tho to make it more explicit what's being done and why would be in order here however. -- Tom Rini (TR1265) http://gate.crashing.org/~trini/ ^ permalink raw reply [flat|nested] 18+ messages in thread
* [PATCH] configurable LOG_BUF_SIZE (updated) 2003-01-06 21:06 ` Randy.Dunlap 2003-01-06 21:26 ` Tomas Szepe @ 2003-01-06 23:30 ` Randy.Dunlap 2003-01-06 23:57 ` Andrew Morton 2003-01-07 0:12 ` [PATCH] configurable LOG_BUF_SIZE Roman Zippel 2 siblings, 1 reply; 18+ messages in thread From: Randy.Dunlap @ 2003-01-06 23:30 UTC (permalink / raw) To: Linus Torvalds; +Cc: Tom Rini, linux-kernel | | On Mon, 6 Jan 2003, Linus Torvalds wrote: | | | | | No, the reason I'm not crazy about it is that I simply _hate_ having too | | | many user knobs to tweak. I don't like tweaking like that, it's just | | | disturbing. | | |--------------------------------------------------------------------------- | | | I'd probably be happier if the current one didn't even _ask_ the user (or| | | | only asked the user if kernel debugging is enabled), and just silently | | | | defaulted to the normal values. | | | |--------------------------------------------------------------------------- Linus, Here's a patch to the 2.5.54-bk4 snapshot that moves the Log Buffer size to Kernel hacking, shows it only if Debugging is enabled, and uses default values otherwise. Please apply. -- ~Randy arch/alpha/Kconfig | 27 +++++++++++++++++++++++++++ arch/arm/Kconfig | 27 +++++++++++++++++++++++++++ arch/cris/Kconfig | 27 +++++++++++++++++++++++++++ arch/i386/Kconfig | 27 +++++++++++++++++++++++++++ arch/ia64/Kconfig | 27 +++++++++++++++++++++++++++ arch/m68k/Kconfig | 27 +++++++++++++++++++++++++++ arch/m68knommu/Kconfig | 27 +++++++++++++++++++++++++++ arch/mips/Kconfig | 27 +++++++++++++++++++++++++++ arch/mips64/Kconfig | 27 +++++++++++++++++++++++++++ arch/parisc/Kconfig | 27 +++++++++++++++++++++++++++ arch/ppc/Kconfig | 27 +++++++++++++++++++++++++++ arch/ppc64/Kconfig | 27 +++++++++++++++++++++++++++ arch/s390/Kconfig | 27 +++++++++++++++++++++++++++ arch/s390x/Kconfig | 27 +++++++++++++++++++++++++++ arch/sh/Kconfig | 27 +++++++++++++++++++++++++++ arch/sparc/Kconfig | 27 +++++++++++++++++++++++++++ arch/sparc64/Kconfig | 27 +++++++++++++++++++++++++++ arch/um/Kconfig | 27 +++++++++++++++++++++++++++ arch/v850/Kconfig | 27 +++++++++++++++++++++++++++ arch/x86_64/Kconfig | 27 +++++++++++++++++++++++++++ init/Kconfig | 45 --------------------------------------------- 21 files changed, 540 insertions(+), 45 deletions(-) --- ./arch/ppc/Kconfig%LGBUF Wed Jan 1 19:23:15 2003 +++ ./arch/ppc/Kconfig Mon Jan 6 14:45:33 2003 @@ -1623,6 +1623,33 @@ config SERIAL_TEXT_DEBUG bool "Support for early boot texts over serial port" depends on 4xx || GT64260 || LOPEC || MCPN765 || PPLUS || PRPMC800 || SANDPOINT || ZX4500 + +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif config OCP bool --- ./arch/i386/Kconfig%LGBUF Wed Jan 1 19:21:10 2003 +++ ./arch/i386/Kconfig Mon Jan 6 14:27:33 2003 @@ -1583,6 +1583,33 @@ If you don't debug the kernel, you can say N, but we may not be able to solve problems without frame pointers. +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + config X86_EXTRA_IRQS bool depends on X86_LOCAL_APIC || X86_VOYAGER --- ./arch/m68k/Kconfig%LGBUF Wed Jan 1 19:22:20 2003 +++ ./arch/m68k/Kconfig Mon Jan 6 14:42:46 2003 @@ -1805,6 +1805,33 @@ config DEBUG_BUGVERBOSE bool "Verbose BUG() reporting" depends on DEBUG_KERNEL + +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif endmenu --- ./arch/sparc/Kconfig%LGBUF Wed Jan 1 19:20:49 2003 +++ ./arch/sparc/Kconfig Mon Jan 6 14:46:41 2003 @@ -1024,6 +1024,33 @@ If you say Y here, various routines which may sleep will become very noisy if they are called with a spinlock held. +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/sparc64/Kconfig%LGBUF Wed Jan 1 19:23:01 2003 +++ ./arch/sparc64/Kconfig Mon Jan 6 14:47:10 2003 @@ -1661,6 +1661,33 @@ depends on STACK_DEBUG default y +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/m68knommu/Kconfig%LGBUF Wed Jan 1 19:22:32 2003 +++ ./arch/m68knommu/Kconfig Mon Jan 6 14:43:59 2003 @@ -710,6 +710,33 @@ help Disable the CPU's BDM signals. +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/alpha/Kconfig%LGBUF Wed Jan 1 19:22:44 2003 +++ ./arch/alpha/Kconfig Mon Jan 6 14:40:52 2003 @@ -982,6 +982,33 @@ verbose debugging messages. If you suspect a semaphore problem or a kernel hacker asks for this option then say Y. Otherwise say N. +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/cris/Kconfig%LGBUF Wed Jan 1 19:23:05 2003 +++ ./arch/cris/Kconfig Mon Jan 6 14:41:54 2003 @@ -710,6 +710,33 @@ depends on PROFILE default "2" +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/mips/Kconfig%LGBUF Wed Jan 1 19:21:58 2003 +++ ./arch/mips/Kconfig Mon Jan 6 14:44:17 2003 @@ -1235,6 +1235,33 @@ depends on SMP default "32" +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/x86_64/Kconfig%LGBUF Wed Jan 1 19:22:53 2003 +++ ./arch/x86_64/Kconfig Mon Jan 6 14:47:53 2003 @@ -701,6 +701,33 @@ to solve problems without frame pointers. Note this is normally not needed on x86-64. +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/ppc64/Kconfig%LGBUF Wed Jan 1 19:22:18 2003 +++ ./arch/ppc64/Kconfig Mon Jan 6 14:45:47 2003 @@ -510,6 +510,33 @@ bool "Include PPCDBG realtime debugging" depends on DEBUG_KERNEL +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/um/Kconfig%LGBUF Wed Jan 1 19:22:00 2003 +++ ./arch/um/Kconfig Mon Jan 6 14:47:26 2003 @@ -262,5 +262,32 @@ If you're involved in UML kernel development and want to use gcov, say Y. If you're unsure, say N. +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu --- ./arch/arm/Kconfig%LGBUF Wed Jan 1 19:22:17 2003 +++ ./arch/arm/Kconfig Mon Jan 6 14:41:45 2003 @@ -1180,6 +1180,33 @@ Say Y here if you want the debug print routines to direct their output to the second serial port on these devices. Saying N will cause the debug messages to appear on the first serial port. + +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif endmenu --- ./arch/parisc/Kconfig%LGBUF Wed Jan 1 19:22:20 2003 +++ ./arch/parisc/Kconfig Mon Jan 6 14:44:47 2003 @@ -375,6 +375,33 @@ symbolic stack backtraces. This increases the size of the kernel somewhat, as all symbols have to be loaded into the kernel image. +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/ia64/Kconfig%LGBUF Wed Jan 1 19:23:09 2003 +++ ./arch/ia64/Kconfig Mon Jan 6 14:42:34 2003 @@ -889,6 +889,33 @@ and restore instructions. It's useful for tracking down spinlock problems, but slow! If you're unsure, select N. +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/mips64/Kconfig%LGBUF Wed Jan 1 19:21:38 2003 +++ ./arch/mips64/Kconfig Mon Jan 6 14:44:33 2003 @@ -678,6 +678,33 @@ depends on SMP default "64" +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/v850/Kconfig%LGBUF Wed Jan 1 19:21:53 2003 +++ ./arch/v850/Kconfig Mon Jan 6 14:47:42 2003 @@ -403,6 +403,33 @@ help Disable the CPU's BDM signals. +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/s390x/Kconfig%LGBUF Wed Jan 1 19:22:05 2003 +++ ./arch/s390x/Kconfig Mon Jan 6 14:46:14 2003 @@ -342,6 +342,33 @@ help If you say Y here, various routines which may sleep will become very noisy if they are called with a spinlock held. + +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif endmenu --- ./arch/sh/Kconfig%LGBUF Wed Jan 1 19:23:15 2003 +++ ./arch/sh/Kconfig Mon Jan 6 14:46:27 2003 @@ -1226,6 +1226,33 @@ when the kernel may crash or hang before the serial console is initialised. If unsure, say N. +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif + endmenu source "security/Kconfig" --- ./arch/s390/Kconfig%LGBUF Wed Jan 1 19:21:48 2003 +++ ./arch/s390/Kconfig Mon Jan 6 14:46:03 2003 @@ -328,6 +328,33 @@ help If you say Y here, various routines which may sleep will become very noisy if they are called with a spinlock held. + +if DEBUG_KERNEL +config LOG_BUF_SHIFT + int "Kernel log buffer size" + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB +endif + +if !DEBUG_KERNEL +config LOG_BUF_SHIFT + int + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 +endif endmenu --- ./init/Kconfig%LGBUF Mon Jan 6 11:52:14 2003 +++ ./init/Kconfig Mon Jan 6 11:55:00 2003 @@ -82,51 +82,6 @@ building a kernel for install/rescue disks or your system is very limited in memory. -choice - prompt "Kernel log buffer size" - default LOG_BUF_SHIFT_17 if ARCH_S390 - default LOG_BUF_SHIFT_16 if X86_NUMAQ || IA64 - default LOG_BUF_SHIFT_15 if SMP - default LOG_BUF_SHIFT_14 - help - Select kernel log buffer size from this list (power of 2). - Defaults: 17 (=> 128 KB for S/390) - 16 (=> 64 KB for x86 NUMAQ or IA-64) - 15 (=> 32 KB for SMP) - 14 (=> 16 KB for uniprocessor) - -config LOG_BUF_SHIFT_17 - bool "128 KB" - default y if ARCH_S390 - -config LOG_BUF_SHIFT_16 - bool "64 KB" - default y if X86_NUMAQ || IA64 - -config LOG_BUF_SHIFT_15 - bool "32 KB" - default y if SMP - -config LOG_BUF_SHIFT_14 - bool "16 KB" - -config LOG_BUF_SHIFT_13 - bool "8 KB" - -config LOG_BUF_SHIFT_12 - bool "4 KB" - -endchoice - -config LOG_BUF_SHIFT - int - default 17 if LOG_BUF_SHIFT_17=y - default 16 if LOG_BUF_SHIFT_16=y - default 15 if LOG_BUF_SHIFT_15=y - default 14 if LOG_BUF_SHIFT_14=y - default 13 if LOG_BUF_SHIFT_13=y - default 12 if LOG_BUF_SHIFT_12=y - endmenu ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE (updated) 2003-01-06 23:30 ` [PATCH] configurable LOG_BUF_SIZE (updated) Randy.Dunlap @ 2003-01-06 23:57 ` Andrew Morton 2003-01-06 23:57 ` Randy.Dunlap 2003-01-07 0:44 ` [PATCH] configurable LOG_BUF_SIZE (update-2) Randy.Dunlap 0 siblings, 2 replies; 18+ messages in thread From: Andrew Morton @ 2003-01-06 23:57 UTC (permalink / raw) To: Randy.Dunlap; +Cc: Linus Torvalds, Tom Rini, linux-kernel "Randy.Dunlap" wrote: > > ... > arch/alpha/Kconfig | 27 +++++++++++++++++++++++++++ > arch/arm/Kconfig | 27 +++++++++++++++++++++++++++ > arch/cris/Kconfig | 27 +++++++++++++++++++++++++++ > arch/i386/Kconfig | 27 +++++++++++++++++++++++++++ > arch/ia64/Kconfig | 27 +++++++++++++++++++++++++++ > arch/m68k/Kconfig | 27 +++++++++++++++++++++++++++ > arch/m68knommu/Kconfig | 27 +++++++++++++++++++++++++++ > arch/mips/Kconfig | 27 +++++++++++++++++++++++++++ > arch/mips64/Kconfig | 27 +++++++++++++++++++++++++++ > arch/parisc/Kconfig | 27 +++++++++++++++++++++++++++ > arch/ppc/Kconfig | 27 +++++++++++++++++++++++++++ > arch/ppc64/Kconfig | 27 +++++++++++++++++++++++++++ > arch/s390/Kconfig | 27 +++++++++++++++++++++++++++ > arch/s390x/Kconfig | 27 +++++++++++++++++++++++++++ > arch/sh/Kconfig | 27 +++++++++++++++++++++++++++ > arch/sparc/Kconfig | 27 +++++++++++++++++++++++++++ > arch/sparc64/Kconfig | 27 +++++++++++++++++++++++++++ > arch/um/Kconfig | 27 +++++++++++++++++++++++++++ > arch/v850/Kconfig | 27 +++++++++++++++++++++++++++ > arch/x86_64/Kconfig | 27 +++++++++++++++++++++++++++ > init/Kconfig | 45 --------------------------------------------- > 21 files changed, 540 insertions(+), 45 deletions(-) Oh gack. And you've got stuff like "if numaq" in the sparc64 config files. You did have a version which instantiated a common $TOPDIR/kernel/Kconfig and just included that in arch/<arch>/Kconfig. Seems a better approach to me. ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE (updated) 2003-01-06 23:57 ` Andrew Morton @ 2003-01-06 23:57 ` Randy.Dunlap 2003-01-07 0:12 ` Randy.Dunlap 2003-01-07 0:44 ` [PATCH] configurable LOG_BUF_SIZE (update-2) Randy.Dunlap 1 sibling, 1 reply; 18+ messages in thread From: Randy.Dunlap @ 2003-01-06 23:57 UTC (permalink / raw) To: Andrew Morton; +Cc: Linus Torvalds, Tom Rini, linux-kernel On Mon, 6 Jan 2003, Andrew Morton wrote: | "Randy.Dunlap" wrote: | > | > ... | > 21 files changed, 540 insertions(+), 45 deletions(-) | | Oh gack. And you've got stuff like "if numaq" in the sparc64 | config files. | | You did have a version which instantiated a common $TOPDIR/kernel/Kconfig | and just included that in arch/<arch>/Kconfig. Seems a better | approach to me. Yes, I like that better also. This is a bit like design by committee. :( I'm just trying to get it completed... and will update some more. -- ~Randy ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE (updated) 2003-01-06 23:57 ` Randy.Dunlap @ 2003-01-07 0:12 ` Randy.Dunlap 0 siblings, 0 replies; 18+ messages in thread From: Randy.Dunlap @ 2003-01-07 0:12 UTC (permalink / raw) To: Andrew Morton; +Cc: Linus Torvalds, Tom Rini, linux-kernel On Mon, 6 Jan 2003, Randy.Dunlap wrote: | On Mon, 6 Jan 2003, Andrew Morton wrote: | | | "Randy.Dunlap" wrote: | | > | | > ... | | > 21 files changed, 540 insertions(+), 45 deletions(-) | | | | Oh gack. And you've got stuff like "if numaq" in the sparc64 | | config files. | | | | You did have a version which instantiated a common $TOPDIR/kernel/Kconfig | | and just included that in arch/<arch>/Kconfig. Seems a better | | approach to me. | | Yes, I like that better also. This is a bit like design by committee. :( | I'm just trying to get it completed... and will update some more. Linus, I withdraw that previous patch and will send the one that I like and want, and will see how it's received/accepted. -- ~Randy ^ permalink raw reply [flat|nested] 18+ messages in thread
* [PATCH] configurable LOG_BUF_SIZE (update-2) 2003-01-06 23:57 ` Andrew Morton 2003-01-06 23:57 ` Randy.Dunlap @ 2003-01-07 0:44 ` Randy.Dunlap 1 sibling, 0 replies; 18+ messages in thread From: Randy.Dunlap @ 2003-01-07 0:44 UTC (permalink / raw) To: Andrew Morton; +Cc: Linus Torvalds, Tom Rini, linux-kernel On Mon, 6 Jan 2003, Andrew Morton wrote: | "Randy.Dunlap" wrote: | > | > ... | > 21 files changed, 540 insertions(+), 45 deletions(-) | | Oh gack. And you've got stuff like "if numaq" in the sparc64 | config files. | | You did have a version which instantiated a common $TOPDIR/kernel/Kconfig | and just included that in arch/<arch>/Kconfig. Seems a better | approach to me. Andrew, I don't see a need just now for the new kernel/Kconfig file since dependency/ordering issues are (supposed to be) gone in Kconfig vs. old config.in files. However, having the Log Buffer size selection in only one place instead of in 20 arch-specific files is a good thing IMO. Here's a much smaller patch that just changes the current (2.5.54-bk4) Kconfig to depend on DEBUG_KERNEL (could be EXPERIMENTAL though) instead of always making it visible, and makes it one number (a shift value). I'd like to have this version applied to 2.5.54++. Linus, how is it? Thanks, -- ~Randy --- ./init/Kconfig%LGBUF Mon Jan 6 16:01:55 2003 +++ ./init/Kconfig Mon Jan 6 16:38:35 2003 @@ -82,50 +82,21 @@ building a kernel for install/rescue disks or your system is very limited in memory. -choice - prompt "Kernel log buffer size" - default LOG_BUF_SHIFT_17 if ARCH_S390 - default LOG_BUF_SHIFT_16 if X86_NUMAQ || IA64 - default LOG_BUF_SHIFT_15 if SMP - default LOG_BUF_SHIFT_14 - help - Select kernel log buffer size from this list (power of 2). - Defaults: 17 (=> 128 KB for S/390) - 16 (=> 64 KB for x86 NUMAQ or IA-64) - 15 (=> 32 KB for SMP) - 14 (=> 16 KB for uniprocessor) - -config LOG_BUF_SHIFT_17 - bool "128 KB" - default y if ARCH_S390 - -config LOG_BUF_SHIFT_16 - bool "64 KB" - default y if X86_NUMAQ || IA64 - -config LOG_BUF_SHIFT_15 - bool "32 KB" - default y if SMP - -config LOG_BUF_SHIFT_14 - bool "16 KB" - -config LOG_BUF_SHIFT_13 - bool "8 KB" - -config LOG_BUF_SHIFT_12 - bool "4 KB" - -endchoice - config LOG_BUF_SHIFT - int - default 17 if LOG_BUF_SHIFT_17=y - default 16 if LOG_BUF_SHIFT_16=y - default 15 if LOG_BUF_SHIFT_15=y - default 14 if LOG_BUF_SHIFT_14=y - default 13 if LOG_BUF_SHIFT_13=y - default 12 if LOG_BUF_SHIFT_12=y + int "Kernel log buffer size" if DEBUG_KERNEL + default 17 if ARCH_S390 + default 16 if X86_NUMAQ || IA64 + default 15 if SMP + default 14 + help + Select kernel log buffer size as a power of 2. + Defaults and Examples: + 17 => 128 KB for S/390 + 16 => 64 KB for x86 NUMAQ or IA-64 + 15 => 32 KB for SMP + 14 => 16 KB for uniprocessor + 13 => 8 KB + 12 => 4 KB endmenu ^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [PATCH] configurable LOG_BUF_SIZE 2003-01-06 21:06 ` Randy.Dunlap 2003-01-06 21:26 ` Tomas Szepe 2003-01-06 23:30 ` [PATCH] configurable LOG_BUF_SIZE (updated) Randy.Dunlap @ 2003-01-07 0:12 ` Roman Zippel 2 siblings, 0 replies; 18+ messages in thread From: Roman Zippel @ 2003-01-07 0:12 UTC (permalink / raw) To: Randy.Dunlap; +Cc: Linus Torvalds, Tom Rini, linux-kernel, Sam Ravnborg, szepe Hi, "Randy.Dunlap" wrote: > +config LOG_BUF_SHIFT > + int "Kernel log buffer size" > + depends on DEBUG_KERNEL Just change this into: int "Kernel log buffer size" if DEBUG_KERNEL > + default 17 if ARCH_S390 > + default 16 if X86_NUMAQ || IA64 > + default 15 if SMP > + default 14 > + help > + Select kernel log buffer size as a power of 2. > + Defaults and Examples: > + 17 (=> 128 KB for S/390) > + 16 (=> 64 KB for x86 NUMAQ or IA-64) > + 15 (=> 32 KB for SMP) > + 14 (=> 16 KB for uniprocessor) > + 13 (=> 8 KB) > + 12 (=> 4 KB) and you don't need this: > +config LOG_BUF_SHIFT > + int > + depends on !DEBUG_KERNEL > + default 17 if ARCH_S390 > + default 16 if X86_NUMAQ || IA64 > + default 15 if SMP > + default 14 bye, Roman ^ permalink raw reply [flat|nested] 18+ messages in thread
end of thread, other threads:[~2003-01-07 0:38 UTC | newest] Thread overview: 18+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2003-01-02 23:09 [PATCH] configurable LOG_BUF_SIZE Randy.Dunlap 2003-01-06 18:50 ` Tom Rini 2003-01-06 18:57 ` Randy.Dunlap 2003-01-06 19:06 ` Tom Rini 2003-01-06 19:05 ` Randy.Dunlap 2003-01-06 19:15 ` Tom Rini 2003-01-06 19:16 ` Linus Torvalds 2003-01-06 19:20 ` Randy.Dunlap 2003-01-06 21:06 ` Randy.Dunlap 2003-01-06 21:26 ` Tomas Szepe 2003-01-06 22:04 ` Randy.Dunlap 2003-01-06 22:56 ` Tom Rini 2003-01-06 23:30 ` [PATCH] configurable LOG_BUF_SIZE (updated) Randy.Dunlap 2003-01-06 23:57 ` Andrew Morton 2003-01-06 23:57 ` Randy.Dunlap 2003-01-07 0:12 ` Randy.Dunlap 2003-01-07 0:44 ` [PATCH] configurable LOG_BUF_SIZE (update-2) Randy.Dunlap 2003-01-07 0:12 ` [PATCH] configurable LOG_BUF_SIZE Roman Zippel
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox