]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: make pid available for uevents without debugfs
authorClaudio Imbrenda <imbrenda@linux.vnet.ibm.com>
Mon, 24 Jul 2017 11:40:03 +0000 (13:40 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 26 Jul 2017 16:57:44 +0000 (18:57 +0200)
commitac6e541c1c797d3ba3c295dd8afe2dc42df9ad4b
tree85c15472318b860b001748fa9e7f0734f09b74d8
parent698fdfda3c45d8e89a32c0c6c4bcbb0b4a140d14
KVM: make pid available for uevents without debugfs

Simplify and improve the code so that the PID is always available in
the uevent even when debugfs is not available.

This adds a userspace_pid field to struct kvm, as per Radim's
suggestion, so that the PID can be retrieved on destruction too.

Acked-by: Janosch Frank <frankja@linux.vnet.ibm.com>
Fixes: 50bac4a4c6e09b ("KVM: trigger uevents when creating or destroying a VM")
Signed-off-by: Claudio Imbrenda <imbrenda@linux.vnet.ibm.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
include/linux/kvm_host.h
virt/kvm/kvm_main.c