kernel - Expand page count fields to 64 bits
* 32 bit page count fields limit us to 8TB of ram. Expand to allow
up to the DMAP limit (32TB). Do an initial pass on various page
count fields and change them from int's to long's or vm_pindex_t's.
* Fix a 32-bit overflow in the pv_entry initialization code.
pv_entry_max = shpgperproc * maxproc + vm_page_array_size;
2000 * 1046516 + pages_of_phys_memory;
maxproc is 1046516 @ 512GB. This calculation overflows its 32
bit signed variable somewhere between 256G and 512G of ram. This
can lead to a zinitna() allocation in pvzone that is much too
large.
Reported-by: zrj