]> git.ipfire.org Git - thirdparty/libvirt.git/commit
Add support for an explicit guest reboot event
authorDaniel P. Berrange <berrange@redhat.com>
Thu, 18 Mar 2010 15:25:38 +0000 (15:25 +0000)
committerDaniel P. Berrange <berrange@redhat.com>
Fri, 26 Mar 2010 13:52:43 +0000 (13:52 +0000)
commit8613273458f3df4ac9fb4eadd0fcd504fe72ced0
treeb76e938cbe12a474afe1cf1753b8c4bbf39f829e
parentd51638d0adb75eccf3170d8ef4faf652e8e2d626
Add support for an explicit guest reboot event

The reboot event is not a normal lifecycle event, since the
virtual machine on the host does not change state. Rather the
guest OS is resetting the virtual CPUs. ie, the QEMU process
does not restart. Thus, this does not belong in the current
lifecycle events callback.

This introduces a new event type

    VIR_DOMAIN_EVENT_ID_REBOOT

It takes no parameters, besides the virDomainPtr, so it can
use the generic callback signature.

* daemon/remote.c: Dispatch reboot events to client
* examples/domain-events/events-c/event-test.c: Watch for
  reboot events
* include/libvirt/libvirt.h.in: Define new reboot event ID
* src/conf/domain_event.c, src/conf/domain_event.h,
  src/libvirt_private.syms: Extend API to handle reboot events
* src/qemu/qemu_driver.c: Connect to the QEMU monitor event
  for reboots and emit a libvirt reboot event
* src/remote/remote_driver.c: Receive and dispatch reboot
  events to application
* src/remote/remote_protocol.x: Wire protocol definition for
  reboot events
12 files changed:
daemon/remote.c
daemon/remote_dispatch_table.h
examples/domain-events/events-c/event-test.c
include/libvirt/libvirt.h.in
src/conf/domain_event.c
src/conf/domain_event.h
src/libvirt_private.syms
src/qemu/qemu_driver.c
src/remote/remote_driver.c
src/remote/remote_protocol.c
src/remote/remote_protocol.h
src/remote/remote_protocol.x