* Re: [PATCH] Fix for hugetlb-add-map_hugetlb-for-mmaping-pseudo-anonymous-huge-page-regions.patch in -mm
[not found] ` <1253011613-6429-1-git-send-email-ebmunson@us.ibm.com>
@ 2009-09-15 20:53 ` Hugh Dickins
2010-02-08 22:56 ` Randy Dunlap
0 siblings, 1 reply; 3+ messages in thread
From: Hugh Dickins @ 2009-09-15 20:53 UTC (permalink / raw)
To: Eric B Munson
Cc: akpm, linux-kernel, linux-mm, linux-man, mtk.manpages,
randy.dunlap, Arnd Bergman
On Tue, 15 Sep 2009, Eric B Munson wrote:
> Resending because this seems to have fallen between the cracks.
Yes, indeed. I think it isn't quite what Arnd was suggesting, but I
agree with you that we might as well go for 0x080000 (so that even Alpha
can be just a cut-and-paste job from asm-generic), and right now it's
more important to finalize the number than what file it appears in.
Acked-by: Hugh Dickins <hugh.dickins@tiscali.co.uk>
>
> The patch
> hugetlb-add-map_hugetlb-for-mmaping-pseudo-anonymous-huge-page-regions.patch
> used the value 0x40 for MAP_HUGETLB which is the same value used for
> various other flags on some architectures. This collision causes
> unexpected use of huge pages in the best case and mmap to fail with
> ENOMEM or ENOSYS in the worst. This patch changes the value for
> MAP_HUGETLB to a value that is not currently used on any arch.
>
> This patch should be considered a fix to
> hugetlb-add-map_hugetlb-for-mmaping-pseudo-anonymous-huge-page-regions.patch.
>
> Reported-by: Hugh Dickins <hugh.dickins@tiscali.co.uk>
> Signed-off-by: Eric B Munson <ebmunson@us.ibm.com>
> ---
> include/asm-generic/mman-common.h | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/include/asm-generic/mman-common.h b/include/asm-generic/mman-common.h
> index 12f5982..e6adb68 100644
> --- a/include/asm-generic/mman-common.h
> +++ b/include/asm-generic/mman-common.h
> @@ -19,7 +19,7 @@
> #define MAP_TYPE 0x0f /* Mask for type of mapping */
> #define MAP_FIXED 0x10 /* Interpret addr exactly */
> #define MAP_ANONYMOUS 0x20 /* don't use a file */
> -#define MAP_HUGETLB 0x40 /* create a huge page mapping */
> +#define MAP_HUGETLB 0x080000 /* create a huge page mapping */
>
> #define MS_ASYNC 1 /* sync memory asynchronously */
> #define MS_INVALIDATE 2 /* invalidate the caches */
> --
> 1.6.3.2
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Fix for hugetlb-add-map_hugetlb-for-mmaping-pseudo-anonymous-huge-page-regions.patch in -mm
2009-09-15 20:53 ` [PATCH] Fix for hugetlb-add-map_hugetlb-for-mmaping-pseudo-anonymous-huge-page-regions.patch in -mm Hugh Dickins
@ 2010-02-08 22:56 ` Randy Dunlap
2010-02-09 15:01 ` Arnd Bergmann
0 siblings, 1 reply; 3+ messages in thread
From: Randy Dunlap @ 2010-02-08 22:56 UTC (permalink / raw)
To: Hugh Dickins
Cc: Eric B Munson, akpm, linux-kernel, linux-mm, linux-man,
mtk.manpages, Arnd Bergman
On Tue, 15 Sep 2009 21:53:12 +0100 (BST) Hugh Dickins wrote:
> On Tue, 15 Sep 2009, Eric B Munson wrote:
> > Resending because this seems to have fallen between the cracks.
>
> Yes, indeed. I think it isn't quite what Arnd was suggesting, but I
> agree with you that we might as well go for 0x080000 (so that even Alpha
> can be just a cut-and-paste job from asm-generic), and right now it's
> more important to finalize the number than what file it appears in.
>
> Acked-by: Hugh Dickins <hugh.dickins@tiscali.co.uk>
so what happened with this patch ??
> >
> > The patch
> > hugetlb-add-map_hugetlb-for-mmaping-pseudo-anonymous-huge-page-regions.patch
> > used the value 0x40 for MAP_HUGETLB which is the same value used for
> > various other flags on some architectures. This collision causes
> > unexpected use of huge pages in the best case and mmap to fail with
> > ENOMEM or ENOSYS in the worst. This patch changes the value for
> > MAP_HUGETLB to a value that is not currently used on any arch.
> >
> > This patch should be considered a fix to
> > hugetlb-add-map_hugetlb-for-mmaping-pseudo-anonymous-huge-page-regions.patch.
> >
> > Reported-by: Hugh Dickins <hugh.dickins@tiscali.co.uk>
> > Signed-off-by: Eric B Munson <ebmunson@us.ibm.com>
> > ---
> > include/asm-generic/mman-common.h | 2 +-
> > 1 files changed, 1 insertions(+), 1 deletions(-)
> >
> > diff --git a/include/asm-generic/mman-common.h b/include/asm-generic/mman-common.h
> > index 12f5982..e6adb68 100644
> > --- a/include/asm-generic/mman-common.h
> > +++ b/include/asm-generic/mman-common.h
> > @@ -19,7 +19,7 @@
> > #define MAP_TYPE 0x0f /* Mask for type of mapping */
> > #define MAP_FIXED 0x10 /* Interpret addr exactly */
> > #define MAP_ANONYMOUS 0x20 /* don't use a file */
> > -#define MAP_HUGETLB 0x40 /* create a huge page mapping */
> > +#define MAP_HUGETLB 0x080000 /* create a huge page mapping */
> >
> > #define MS_ASYNC 1 /* sync memory asynchronously */
> > #define MS_INVALIDATE 2 /* invalidate the caches */
> > --
---
~Randy
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Fix for hugetlb-add-map_hugetlb-for-mmaping-pseudo-anonymous-huge-page-regions.patch in -mm
2010-02-08 22:56 ` Randy Dunlap
@ 2010-02-09 15:01 ` Arnd Bergmann
0 siblings, 0 replies; 3+ messages in thread
From: Arnd Bergmann @ 2010-02-09 15:01 UTC (permalink / raw)
To: Randy Dunlap
Cc: Hugh Dickins, Eric B Munson, akpm, linux-kernel, linux-mm,
linux-man, mtk.manpages
On Monday 08 February 2010, Randy Dunlap wrote:
> On Tue, 15 Sep 2009 21:53:12 +0100 (BST) Hugh Dickins wrote:
>
> > On Tue, 15 Sep 2009, Eric B Munson wrote:
> > > Resending because this seems to have fallen between the cracks.
> >
> > Yes, indeed. I think it isn't quite what Arnd was suggesting, but I
> > agree with you that we might as well go for 0x080000 (so that even Alpha
> > can be just a cut-and-paste job from asm-generic), and right now it's
> > more important to finalize the number than what file it appears in.
> >
> > Acked-by: Hugh Dickins <hugh.dickins@tiscali.co.uk>
>
> so what happened with this patch ??
In a later revision, we agreed to put the definition into
asm-generic/mman.h, where it was merged in 2.6.32.
Arnd
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-02-09 15:02 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1252487811-9205-1-git-send-email-ebmunson@us.ibm.com>
[not found] ` <1253011613-6429-1-git-send-email-ebmunson@us.ibm.com>
2009-09-15 20:53 ` [PATCH] Fix for hugetlb-add-map_hugetlb-for-mmaping-pseudo-anonymous-huge-page-regions.patch in -mm Hugh Dickins
2010-02-08 22:56 ` Randy Dunlap
2010-02-09 15:01 ` Arnd Bergmann
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox