Patent ID: 11880704
Assignee: RED HAT, INC.
Field: Computer technology (Electrical engineering)
Classification: CPC G | IPC G

Claim 6:
7. A system comprising:
a memory; and
a processing device operatively coupled to the memory, the processing device to execute a hypervisor to:
receive a request to link a first virtual machine as a nested guest within a second virtual machine;
determine whether the second virtual machine is encrypted and the first virtual machine is targeted to be encrypted;

in response to determining that the second virtual machine is encrypted and the first virtual machine is targeted to be encrypted, link the first virtual machine as a nested guest within the second virtual machine during creation of the first virtual machine;
identify a context of the second virtual machine;
provide, to a context of the first virtual machine, a parent context pointer indicating the context of the second virtual machine;
detect a privileged instruction at the first virtual machine; and
in response to detecting the privileged instruction, exit from the context of the first virtual machine and switch to the context of the second virtual machine using the parent context pointer instead of switching to the hypervisor.