HomeFreeBSD

Use vm_map_insert() instead of vm_map_find() in elf_map_insert().

Description

Use vm_map_insert() instead of vm_map_find() in elf_map_insert().

Elf_map_insert() needs to create mapping at the known fixed address.
Usage of vm_map_find() assumes, on the other hand, that any suitable
address space range above or equal the specified hint, is acceptable.
Due to operating on the fresh or cleared address space, vm_map_find()
usually creates mapping starting exactly at hint.

Switch to vm_map_insert() use to clearly request fixed mapping from
the VM.

Tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks

Details

Provenance
kibAuthored on
Parents
rS314486: When deallocating the vm object in elf_map_insert() due to
Branches
Unknown
Tags
Unknown