All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: Helge Deller <deller@gmx.de>
Cc: linux-parisc@vger.kernel.org,
	James Bottomley <James.Bottomley@hansenpartnership.com>,
	dave.anglin@bell.net
Subject: Re: [PATCH] parisc: fix re-mmap() of shared file to same fixed address
Date: Sun, 24 Nov 2013 23:41:22 -0500	[thread overview]
Message-ID: <201311242341.23301.vapier@gentoo.org> (raw)
In-Reply-To: <20131120220742.GA23304@p100.box>

[-- Attachment #1: Type: Text/Plain, Size: 1273 bytes --]

On Wednesday 20 November 2013 17:07:42 Helge Deller wrote:
> locale-gen from glibc showed a strange problem on parisc:

pedantic: locale-gen is from distros while glibc itself provides localedef.

> mmap2(NULL, 536870912, PROT_NONE, MAP_SHARED, 3, 0) = 0x42a54000
> mmap2(0x42a54000, 103860, PROT_READ|PROT_WRITE, MAP_SHARED|MAP_FIXED, 3, 0)
> = -1 EINVAL (Invalid argument)
> 
> Basically it was just trying to re-mmap() a file at the same address
> which it was given by a previous mmap() call. But this remapping failed
> with EINVAL.
> 
> The problem is, that when MAP_FIXED and MAP_SHARED flags were used, we
> didn't included the mapping-based offset when we verified the alignment of
> the given fixed address against the offset which we calculated it in the
> previous call.

hmm, which version of glibc were you trying ?  we landed this change recently:
https://sourceware.org/git/?p=glibc.git;a=commitdiff_plain;h=17db6e8d6b12f55e312fcab46faf5d332c806fb6

it's part of glibc-2.18.  we know earlier versions of localedef failed on 
systems like parisc, although it seemed to really only creep up on 64bit 
kernels reliably.

based on your description, it sounds like independent bugs, but it also seems 
a little coincidental ...
-mike

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

  reply	other threads:[~2013-11-25  4:41 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-20 22:07 [PATCH] parisc: fix re-mmap() of shared file to same fixed address Helge Deller
2013-11-25  4:41 ` Mike Frysinger [this message]
2013-11-25 13:19   ` John David Anglin
2013-11-25 20:43   ` Helge Deller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201311242341.23301.vapier@gentoo.org \
    --to=vapier@gentoo.org \
    --cc=James.Bottomley@hansenpartnership.com \
    --cc=dave.anglin@bell.net \
    --cc=deller@gmx.de \
    --cc=linux-parisc@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.