Re: [PATCH 2/2] mmap: allow MAP_HUGETLB for hugetlbfs files

2013-06-19 Thread Jörn Engel
On Wed, 19 June 2013 09:22:49 +0800, Jianguo Wu wrote: > > We already have is_file_hugepages(). Indeed. Much nicer now. Thanks! Jörn -- The grand essentials of happiness are: something to do, something to love, and something to hope for. -- Allan K. Chalmers -- To unsubscribe from this list:

Re: [PATCH 2/2] mmap: allow MAP_HUGETLB for hugetlbfs files

2013-06-18 Thread Jianguo Wu
Hi Joern, On 2013/6/19 2:47, Joern Engel wrote: > It is counterintuitive at best that mmap'ing a hugetlbfs file with > MAP_HUGETLB fails, while mmap'ing it without will a) succeed and b) > return huge pages. > > Signed-off-by: Joern Engel > --- > mm/mmap.c | 12 ++-- > 1 file changed

[PATCH 2/2] mmap: allow MAP_HUGETLB for hugetlbfs files

2013-06-18 Thread Joern Engel
It is counterintuitive at best that mmap'ing a hugetlbfs file with MAP_HUGETLB fails, while mmap'ing it without will a) succeed and b) return huge pages. Signed-off-by: Joern Engel --- mm/mmap.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/mm/mmap.c b/mm/mm