Liran Alon 917dc6068b KVM: nVMX: Fix vmx_check_nested_events() return value in case an event was reinjected to L2
vmx_check_nested_events() should return -EBUSY only in case there is a
pending L1 event which requires a VMExit from L2 to L1 but such a
VMExit is currently blocked. Such VMExits are blocked either
because nested_run_pending=1 or an event was reinjected to L2.
vmx_check_nested_events() should return 0 in case there are no
pending L1 events which requires a VMExit from L2 to L1 or if
a VMExit from L2 to L1 was done internally.

However, upstream commit which introduced blocking in case an event was
reinjected to L2 (commit acc9ab601327 ("KVM: nVMX: Fix pending events
injection")) contains a bug: It returns -EBUSY even if there are no
pending L1 events which requires VMExit from L2 to L1.

This commit fix this issue.

Fixes: acc9ab601327 ("KVM: nVMX: Fix pending events injection")

Signed-off-by: Liran Alon <liran.alon@oracle.com>
Reviewed-by: Nikita Leshenko <nikita.leshchenko@oracle.com>
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
2017-11-17 13:20:21 +01:00
..
2017-11-15 15:01:28 -08:00
2017-11-17 13:20:01 +01:00
2017-11-17 13:20:01 +01:00
2017-11-14 18:25:40 -08:00
2017-11-15 15:01:28 -08:00
2017-11-15 18:21:03 -08:00
2017-11-14 16:54:12 -08:00
2017-11-15 15:01:28 -08:00
2017-11-15 18:21:00 -08:00
2017-11-14 16:54:12 -08:00
2017-11-14 18:25:40 -08:00
2017-11-14 18:25:40 -08:00
2017-11-16 11:41:22 -08:00
2017-11-14 18:25:40 -08:00
2017-11-15 18:21:04 -08:00
2017-11-15 15:01:28 -08:00
2017-11-15 10:49:15 -08:00
2017-11-16 13:00:24 -08:00
2017-11-15 15:01:28 -08:00