Ralf Baechle wrote:
> On Thu, Jul 04, 2002 at 08:18:41PM +0200, Carsten Langgaard wrote:
> > > any power of 2 > PAGE_SIZE.
> > Ok, I see, but is there any reason for us to be different than the
> > rest of the world ?
> Imho the your question already wrong :-) Any assumption about the
> constant's value in a piece of code is wrong.
> The reason why the constant's value was choosen are virtually indexed
> caches. The value allows attaching of shared memory segment without
> any cache flushes.
> Other architectures also use different values from PAGE_SIZE like IA64 1MB,
> SH 16kB and Sparc not even a constant value accross all architectures
> variants, so unlike what your posting implicates we're not that unusual.
Using PAGE_SIZE is ok, even though it may differ from different architecture,
because SHMLBA is defined as the following in /usr/include/sys/shm.h:
#define SHMLBA (__getpagesize ())
So I would expect the user application and the kernel should have the same
idea of what the size is.
_ _ ____ ___ Carsten Langgaard Mailto:firstname.lastname@example.org
|\ /|||___)(___ MIPS Denmark Direct: +45 4486 5527
| \/ ||| ____) Lautrupvang 4B Switch: +45 4486 5555
TECHNOLOGIES 2750 Ballerup Fax...: +45 4486 5556