On Wed 25 Sep at 19:44:36 +0200 mi...@kernel.org said:
>
> * Timothy Pepper wrote:
>
> > On Wed 25 Sep at 09:30:49 +0200 mi...@kernel.org said:
> > > > info.flags = VM_UNMAPPED_AREA_TOPDOWN;
> > > > info.length = len;
>
On Wed 25 Sep at 09:30:49 +0200 mi...@kernel.org said:
> > info.flags = VM_UNMAPPED_AREA_TOPDOWN;
> > info.length = len;
> > - info.low_limit = PAGE_SIZE;
> > + info.low_limit = max(PAGE_SIZE, PAGE_ALIGN(mmap_min_addr));
> > info.high_limit = mm->mmap_base;
> > info.align_mask =
A security check is performed on mmap addresses in
security/security.c:security_mmap_addr(). It uses mmap_min_addr to insure
mmaps don't get addresses lower than a user configurable guard value
(/proc/sys/vm/mmap_min_addr). The arch specific mmap topdown searches
look for a map candidate address