Re: [RFC PATCH v6 14/92] kvm: introspection: handle introspection commands before returning to guest

2019-08-14 Thread Adalbert Lazăr
On Tue, 13 Aug 2019 16:45:11 +0200, Paolo Bonzini wrote: > On 13/08/19 15:54, Adalbert Lazăr wrote: > > Leaving kvm_vcpu_block() in order to handle a request such as 'pause', > > would cause the vCPU to enter the guest when resumed. Most of the > > time this does not appear to be an

Re: [RFC PATCH v6 14/92] kvm: introspection: handle introspection commands before returning to guest

2019-08-13 Thread Paolo Bonzini
On 13/08/19 15:54, Adalbert Lazăr wrote: > Leaving kvm_vcpu_block() in order to handle a request such as 'pause', > would cause the vCPU to enter the guest when resumed. Most of the > time this does not appear to be an issue, but during early boot it > can happen for a non-boot

Re: [RFC PATCH v6 14/92] kvm: introspection: handle introspection commands before returning to guest

2019-08-13 Thread Adalbert Lazăr
On Tue, 13 Aug 2019 10:26:29 +0200, Paolo Bonzini wrote: > On 09/08/19 17:59, Adalbert Lazăr wrote: > > + prepare_to_swait_exclusive(>wq, , > > + TASK_INTERRUPTIBLE); > > + > > + if (kvm_vcpu_check_block(vcpu) < 0) >

Re: [RFC PATCH v6 14/92] kvm: introspection: handle introspection commands before returning to guest

2019-08-13 Thread Paolo Bonzini
On 09/08/19 17:59, Adalbert Lazăr wrote: > + prepare_to_swait_exclusive(>wq, , > +TASK_INTERRUPTIBLE); > + > + if (kvm_vcpu_check_block(vcpu) < 0) > + break; > + > +

[RFC PATCH v6 14/92] kvm: introspection: handle introspection commands before returning to guest

2019-08-09 Thread Adalbert Lazăr
From: Mihai Donțu The introspection requests (KVM_REQ_INTROSPECTION) are checked by any introspected vCPU in two places: * on its way to guest - vcpu_enter_guest() * when halted - kvm_vcpu_block() In kvm_vcpu_block(), we check to see if there are any introspection requests during the swait