Subject: Re: Increasing SHMMAXPGS
To: Curt Sampson <cjs@cynic.net>
From: Olaf Seibert <rhialto@polderland.nl>
List: tech-kern
Date: 07/08/2002 12:23:35
On Mon 08 Jul 2002 at 10:11:37 +0900, Curt Sampson wrote:
> On Mon, 8 Jul 2002, Olaf Seibert wrote:
> 
> > I had a very similar thought: why not put these shared memory segements
> > in some real directory in a real file system, and then just implement
> > access via mmap()? If one wants to remove an unused shared segment, just
> > rm the file?
> 
> I thought about that too, in fact. The one real advantage this
> gives you is that you've greatly expanded the potential amount of
> shared memory you can allocate.
> 
> As for the rest, well, we already have ipcs and ipcrm, and we have
> to keep them for use with the semaphores and message queues anyway.
> Why spend time re-implementing functionality we already have, when we
> can't even get rid of the old interface?

That is true. But it could be implemented entirely in userland, I
suspect. So the kernel could be a bit smaller. shmat(2) and shmdt(2)
could be done in libc witm mmap, shmget(2) would create a file, if
necessary, and shmctl(2) would stat(2), unlink(2) or chmod(2) it.

That's no solution for  semaphores and message queues but maybe we'll
think of something for them too.

> cjs
-Olaf.
-- 
___ Olaf 'Rhialto' Seibert - rhialto@       -- Woe betide the one who feels
\X/ polderland.nl  -- remorse without sin - Tom Poes, "Het boze oog", 4444.