diff options
author | Raghavendra K T <raghavendra.kt@linux.vnet.ibm.com> | 2013-03-04 23:32:07 +0530 |
---|---|---|
committer | Gleb Natapov <gleb@redhat.com> | 2013-03-11 11:37:08 +0200 |
commit | 3a08a8f9f0936e182d387afd85fdc5d303381521 (patch) | |
tree | 092f3ba314b1822b84fa24af6f211c9388bc566d /include | |
parent | 5da596078f915a62e39a20e582308eab91b88c9a (diff) |
kvm: Record the preemption status of vcpus using preempt notifiers
Note that we mark as preempted only when vcpu's task state was
Running during preemption.
Thanks Jiannan, Avi for preemption notifier ideas. Thanks Gleb, PeterZ
for their precious suggestions. Thanks Srikar for an idea on avoiding
rcu lock while checking task state that improved overcommit numbers.
Reviewed-by: Chegu Vinod <chegu_vinod@hp.com>
Reviewed-by: Marcelo Tosatti <mtosatti@redhat.com>
Signed-off-by: Raghavendra K T <raghavendra.kt@linux.vnet.ibm.com>
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/kvm_host.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h index 9fa13ebc3381..0f4941a9c9c8 100644 --- a/include/linux/kvm_host.h +++ b/include/linux/kvm_host.h @@ -253,6 +253,7 @@ struct kvm_vcpu { bool dy_eligible; } spin_loop; #endif + bool preempted; struct kvm_vcpu_arch arch; }; |