This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH v2] [BZ #10283] localedef: align fixed maps to SHMLBA
- From: "Carlos O'Donell" <carlos at redhat dot com>
- To: David Miller <davem at davemloft dot net>
- Cc: roland at hack dot frob dot com, vapier at gentoo dot org, libc-alpha at sourceware dot org
- Date: Tue, 28 May 2013 17:43:26 -0400
- Subject: Re: [PATCH v2] [BZ #10283] localedef: align fixed maps to SHMLBA
- References: <20130528194042 dot 1EF7B2C074 at topped-with-meat dot com> <20130528 dot 130721 dot 1721261559877509450 dot davem at davemloft dot net> <51A51186 dot 7070904 at redhat dot com> <20130528 dot 132601 dot 2200516495498570890 dot davem at davemloft dot net>
On 05/28/2013 04:26 PM, David Miller wrote:
> From: "Carlos O'Donell" <carlos@redhat.com>
> Date: Tue, 28 May 2013 16:20:22 -0400
>
>> I know it's a little pedantic, but it's not a generic issue, and thus I
>> agree that it should be a part of the OS/hardware support code.
>
> Any OS which allows illegal cache aliases to be created as a result of
> an MMAP call is broken, they signal an error instead.
>
> The standard way to express the required alignment in every single case
> I am aware of is SHMLBA.
>
> And that's why Linux "inherited" this semantic from other systems.
Thanks for the background.
It's unfortunate that POSIX doesn't say more than just:
"If MAP_FIXED is specified, the implementation may require that
addr is a multiple of the page size."
Perhaps we'll get Issue 8 to say something about SHMLBA in the
non-normative RATIONALE section for mmap.
Cheers,
Carlos.