Recursion in the UVA

Andrey Simonenko simon at
Tue May 11 15:58:40 UTC 2010

On Mon, May 10, 2010 at 11:42:26AM -0700, Evan Geller wrote:
> I'm a bit confused how recursion in the UVA works. vm_map_entries are
> allocated from a vm_map_entry zone, but if the vm_map_entry slabs are
> full and it needs to allocate a vm_map_entry to satisfy the mapping,
> there would seem to be a starvation. I also see a uk_recurse field per

There are two types of UMA zones for vm_map_entry structures.  One is
used for system maps (kmapentzone) and another one is used for regular
maps (mapentzone).  When kmapentzone is created it got a flag that force
it to get new items only from items it owns.  Some items are preallocated
for kmapentzone on startup and later kmapentzone gets own object, from
which it will take new items.  So, all items for kmapentzone will be
taken from an object that was already inserted in kernel_map.

For the mapentzone (for regular vm_map_entry structures) items are taken
as usual and new vm_map_entry structures can be created for these allocations,
but required extra vm_map_entry will be allocated from kmapentzone (since
it will belong to some system map) that use own object with own pages for
its items.

More information about the freebsd-hackers mailing list