[lkml]   [2005]   [Jul]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH] i386: Selectable Frequency of the Timer Interrupt
Jesper Juhl wrote:

>On 7/24/05, randy_dunlap <> wrote:
>>On Fri, 15 Jul 2005 05:46:44 +0200 Jesper Juhl wrote:
>>>+static int __init jiffies_increment_setup(char *str)
>>>+ printk(KERN_NOTICE "setting up jiffies_increment : ");
>>>+ if (str) {
>>>+ printk("kernel_hz = %s, ", str);
>>>+ } else {
>>>+ printk("kernel_hz is unset, ");
>>>+ }
>>>+ if (!strncmp("100", str, 3)) {
>>BTW, if someone enters "kernel_hz=1000", this check (above) for "100"
>>matches (detects) 100, not 1000.
>ouch. You are right - thanks. I'll be sure to fix that.
>I haven't had time to look more at this little thing for the last few
>days, but I'll get back to it soon. Thank you for the feedback.
I have to admit that I like paranoid programming, and would rather see
this look for "kernel_hz=" then convert the digits after to an integer
and validate that. It would catch invalid values far better, allow other
values to be either implemented as best as is possible if desired, and
NOT ignore invalid values if they didn't match these predefined strings.

bill davidsen <>
CTO TMR Associates, Inc
Doing interesting things with small computers since 1979

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-07-24 14:56    [W:0.095 / U:0.200 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site