This patch is work in progress, and not ready to use / test. It will probably cause panics.
First attempts at making VM_MAXCPU tunable, and I'm hoping I'll get some feedback on my approach here:
- Create a tunable maxvcpus
- Replace VM_MAXCPU with maxvcpu in loops and dynamic allocations
- Limit that tunable to 21 for now
- Dynamically allocate arrays of size VM_MAXCPU in
- vmx.vmcs, vmx.apic_page, vmx.pir_desc, vmx.guest_msrs, vmx.ctx, vmx.cap, vmx.state
- Dynamically define VMM_STAT_ARRAYS
[ } Dynamically calculate FADT_OFFSET, HPET_OFFSET, MCFG_OFFSET, FACS_OFFSET, DSDT_OFFSET, and remove the 21 vcpu limitation
Only comment on methodology used at this time, the details in the diff are fluid and not worth spending a lot of time on.
Commit message to contain:
Attribution to fabian.freyer_physik.tu-berlin.de for his work on this