mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-06-01 20:05:30 +00:00
update the hugepages algorithm as the following steps. 1. calculate the total hugepages of service vm using the formula. "total memory - the memory consumed by pre-launched VMs - 3G -1G(memory need by service vm supporting virtio gpu) -300M*num(number of virtio gpu instance)" 2. calculate hugepage 2M/1G based post-launched vm memory setting. 3. correct the 2M/1G hugepages with the total hugepages in step 1. "correct_mb, correct_gb= math.modf(total hugepages - the memory consumed by Post_launched vm) hugepages_1gb = hugepages_1gb + correct_gb hugepages_2mb = hugepages_2mb + math.ceil(correct_mb*1024/2)" Tracked-On: #7301 Signed-off-by: Kunhui-Li <kunhuix.li@intel.com> Reviewed-by: Junjie Mao <junjie.mao@intel.com> |
||
---|---|---|
.. | ||
lib | ||
bdf.py | ||
board_capability.py | ||
clos.py | ||
cpu_affinity.py | ||
gpa.py | ||
guest_flags.py | ||
intx.py | ||
main.py | ||
memory_allocator.py | ||
pio.py |