lkml.org 
[lkml]   [1999]   [Aug]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: madvise() first draft
Date
From
Matthew Wilcox wrote:
> On Wed, Aug 25, 1999 at 09:28:55PM -0700, Zack Weinberg wrote:
> > The way it currently works is: after your patch is added to the
> > official kernel, glibc will add the defines to <bits/mman.h> and the
> > syscall stub to the library. Note that madvise() is already a
> > function in libc you can call - it happens to do nothing but return -1
> > with errno set to ENOSYS, but it's there...
> >
> > We've been round and round the duplicate info in kernel and libc
> > headers problem many times, and this is the least bad solution
> > anyone's come up with to date.
>
> It is? How about:
>
> linux/include/public/foo.h
> contains all constants and similar which should be exported to userspace.
>
> linux/include/linux/foo.h
> does #include <public/foo.h> and then contains kernel-specific
> stuff.

I remember Linus didn't want to deal with maintaining an arrangement
like this (or the equivalent version with #ifdef __KERNEL__ around
internal definitions).

It's not always easy to decide what is internal and what isn't, too...

zw

-
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:53    [W:0.064 / U:1.108 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site