Nested virtualization is the ability to run a virtual machine inside another virtual machine. In other words, it’s about running a hypervisor (the guest hypervisor) on top of another hypervisor (the host hypervisor).
How to emulate synchronous exception for Guest Hypervisor (EL1) in Host Hypervisor (EL2)?
Example: Stage 2 address translation fault in Guest OS (EL1) will be routed to Host Hypervisor (EL2), not Guest Hypervisor. How the Guest Hypervisor knows and handles this fault.
Actually the above URL mentioned that:
"Armv8.3-A added the NV and NV1 controls. Accesses to _EL2 registers from EL1 are usually undefined, and accesses would cause an exception to EL1. The NV and NV1 bits cause EL1 accesses to _EL2 registers to trap to EL2 instead. This allows a Guest Hypervisor to run at EL1, with the Host Hypervisor at EL2 emulating some of its operations. NV also traps ERETs from EL1."
For the Stage 2 address translation from Guest OS(EL1), it will be routed to EL2 while the Host Hypervisor is running at. Guest Hypervisor running at EL1 will not notice that.
Thanks for your answer!
My confusion is the exception virtualization e.g. we are in GuestOS (EL1) then we execute "HVC #1" that means an exception will be routed to Hypervisor (EL2). At that time, how the Guest Hypervisor (EL1) knows and handles that exception? or How Host Hypervisor emulate the exception for Guest Hypervisor?
View all questions in Arm Development Platforms forum