Re: don't let mmap allocate down to zero

From: Hugh Dickins
Date: Fri Jan 28 2005 - 10:57:15 EST


On Fri, 28 Jan 2005, Rik van Riel wrote:
>
> The main thing I would really like to preserve is the
> space used for "near-NULL" pointer detection. That is,
> detection of trying to access a large index in a NULL
> pointer array, etc.
>
> I'd be happy to have some arbitrary value for the lower
> boundary...

Almost everything will still have that not-so-near-NULL pointer
detection. It only gets limited to a PAGE_SIZE detection extent
in the case when the app mmaps as much as it possibly can.
I think it should be allowed make that tradeoff.

> > arch/ppc64/mm/hugetlbpage.c (odd place to find it) has its own
> > arch_get_unmapped_area_topdown, should be given a similar fix.
>
> Good point, though a 64 bit architecture is, umm, less
> likely to run all the way down to zero within our lifetime.

I hadn't looked at it that way!

Hugh
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/