On Thu, 19 May 2005, Arjan van de Ven wrote:
> > First off, I think we need a system-call that will return some of
> > the information that now comes from headers. PAGE_SIZE comes to
> > mind. You need this for mmap() but there doesn't seem to be any
> > way to get it. getpagesize() 'C' library just returns something
> > it's swiped from kernel headers when the library was compiled.
> > There are other things like the following that sometimes need
>
> for getpagesize() I can see the point
If that is the case, then that's a bug in that C library, which should be
reported and fixed. When starting a program, i.e. as a result of
execve(), Linux passes the current page size in use in the auxiliary
vector. That value should be retrieved and used by a C library for
platforms that support various page sizes and returned by library calls
like getconf(). For example glibc gets it right.
Maciej
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]