Open sirredbeard opened 1 year ago
@sirredbeard you might want EL2 instead, that's the execution context for nesting on ARM processors.
This is output on a raspberry pi 4 with kvm mode enabled:
CPU: All CPU(s) started at EL2
kvm [1]: Hyp mode initialized successfully
and WSL kernel with kvm enabled:
CPU: All CPU(s) started at EL1
kvm [1]: HYP mode not available
Does EL0 run in hypervisor mode?
I believe you are correct, @elsaco. I went back to the ARM documentation (still learning) and updated the request. Thank you.
Describe the solution you'd like
The EFI bootloader on WSL on ARM starts the CPU at EL1.
[ 0.255558] CPU: All CPU(s) started at EL1
This prevents the WSL kernel from enabling HYP mode:
And this prevents utilizing KVM on WSL on ARM, with a custom kernel built with KVM enabled:
The nestedVirtualization setting in .wslconfig should boot the CPU as EL2 (or, optionally, enabling HYP mode), enabling KVM on WSL on ARM.
Describe alternatives you've considered
Without KVM, virtualization can still be achieved in usermode, but without KVM acceleration.