lkml.org 
[lkml]   [1998]   [Oct]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch] jiffies wraparound [Re: 2.1.125 Show stopper list: Draft]
Andi Kleen wrote:
> > good point. Especially soft-RT-people like the choice of HZ=1000,
> > millisec-accuracy scheduling and timers. I remember someone even used
> > 10000, to get 100 usec accuracy timers. Even a low-end PC can take HZ=10k.
> > That one wraps jiffies every 4 days!
>
> There is only one problem with it: glibc doesn't know about it and returns
> the wrong value to posix conformant programs trying to get it with sysconf().
> Solution: add a readonly sysctl for HZ.

If you're going to do this *please* do PAGE_SIZE at the same time. It suffers
from the same problem on architectures where that's variable (m68k being
the only one I know of - 8K for sun3, 4K for other things) Right now you
need two libc's to solve this problem.

The other posibility would be to create a kernel syscall for sysconf to
return kenrel-specific things - there are several other ones. Also we
should have a real pathconf which will require a new VFS entry point.

However, having HZ and PAGE_SIZE in sysctl is something that I think we
could have in 2.2 still. It's certainly useful to let the user see that
info anyway.

-Mitch

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:45    [W:0.105 / U:0.240 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site