This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: Wrong SHMLBA for MIPS
- From: Daniel Jacobowitz <drow at mvista dot com>
- To: libc-alpha at sources dot redhat dot com
- Date: Tue, 15 Jul 2003 16:42:16 -0400
- Subject: Re: Wrong SHMLBA for MIPS
- References: <20030715203748.GA5284@nevyn.them.org>
On Tue, Jul 15, 2003 at 04:37:48PM -0400, Daniel Jacobowitz wrote:
> A year ago, HJ posted a patch to create a <sys/shm.h> for MIPS. It was
> applied and then reverted, and <bits/shm.h> got a definition of SHMLBA. But
> it's not the right one...
>
> The kernel says:
> #define SHMLBA 0x40000 /* attach addr a multiple of this */
>
> But the MIPS <bits/shm.h> says:
> /* Segment low boundary address multiple. */
> #define SHMLBA (__getpagesize ())
> extern int __getpagesize (void) __THROW __attribute__ ((__const__));
>
> which works out to 4K on MIPS. Am I missing something or should
> <bits/shm.h> be corrected?
More specifically, this.
2003-07-15 Daniel Jacobowitz <drow@mvista.com>
* sysdeps/unix/sysv/linux/mips/bits/shm.h (SHMLBA): Define to 256K.
--- glibc-2.3.2/sysdeps/unix/sysv/linux/mips/bits/shm.h.orig 2003-07-15 16:39:31.000000000 -0400
+++ glibc-2.3.2/sysdeps/unix/sysv/linux/mips/bits/shm.h 2003-07-15 16:40:00.000000000 -0400
@@ -36,7 +36,7 @@
#define SHM_UNLOCK 12 /* unlock segment (root only) */
/* Segment low boundary address multiple. */
-#define SHMLBA (__getpagesize ())
+#define SHMLBA 0x40000
extern int __getpagesize (void) __THROW __attribute__ ((__const__));
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer