Currently an offset is being passed in to mmap() when allocating a region. This is pointless so pass in 0.
Signed-off-by: Mel Gorman <[EMAIL PROTECTED]> --- alloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/alloc.c b/alloc.c index 750b2cb..c118f18 100644 --- a/alloc.c +++ b/alloc.c @@ -89,7 +89,7 @@ void *get_huge_pages(size_t len, ghp_t flags) /* Map the requested region */ buf = mmap(NULL, len, PROT_READ|PROT_WRITE, - MAP_PRIVATE, heap_fd, len); + MAP_PRIVATE, heap_fd, 0); if (buf == MAP_FAILED) { close(heap_fd); ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Libhugetlbfs-devel mailing list Libhugetlbfs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libhugetlbfs-devel