libvirt/src/conf
Eric Blake 6831c1d327 event: pass reason for PM events
Commit 57ddcc23 (v0.9.11) introduced the pmwakeup event, with
an optional 'reason' field reserved for possible future expansion.
But it failed to wire the field through RPC, so even if we do
add a reason in the future, we will be unable to get it back
to the user.

Worse, commit 7ba5defb (v1.0.0) repeated the same mistake with
the pmsuspend_disk event.

As long as we are adding new RPC calls, we might as well fix
the events to actually match the signature so that we don't have
to add yet another RPC in the future if we do decide to start
using the reason field.

* src/remote/remote_protocol.x
(remote_domain_event_callback_pmwakeup_msg)
(remote_domain_event_callback_pmsuspend_msg)
(remote_domain_event_callback_pmsuspend_disk_msg): Add reason
field.
* daemon/remote.c (remoteRelayDomainEventPMWakeup)
(remoteRelayDomainEventPMSuspend)
(remoteRelayDomainEventPMSuspendDisk): Pass reason to client.
* src/conf/domain_event.h (virDomainEventPMWakeupNewFromDom)
(virDomainEventPMSuspendNewFromDom)
(virDomainEventPMSuspendDiskNewFromDom): Require additional
parameter.
* src/conf/domain_event.c (virDomainEventPMClass): New class.
(virDomainEventPMDispose): New function.
(virDomainEventPMWakeupNew*, virDomainEventPMSuspendNew*)
(virDomainEventPMSuspendDiskNew*)
(virDomainEventDispatchDefaultFunc): Use new class.
* src/remote/remote_driver.c (remoteDomainBuildEvent*PM*): Pass
reason through.
* src/remote_protocol-structs: Regenerate.

Signed-off-by: Eric Blake <eblake@redhat.com>
2014-02-12 10:48:16 -07:00
..
capabilities.c Rename 'index' in virCapabilitiesGetCpusForNode 2014-02-11 16:35:33 +01:00
capabilities.h maint: avoid further typedef accidents 2013-10-30 17:02:12 -06:00
cpu_conf.c conf: Always use VIR_ERR_CONFIG_UNSUPPORTED on enumFromString() failures 2014-01-16 11:09:43 +01:00
cpu_conf.h maint: avoid 'const fooPtr' in cpu files 2013-10-14 13:11:20 -06:00
device_conf.c virutil: Move string related functions to virstring.c 2013-05-02 16:56:55 +02:00
device_conf.h Rename util.{c,h} to virutil.{c,h} 2012-12-21 11:19:49 +00:00
domain_audit.c conf: introduce spiceport chardev backend 2014-02-11 13:43:55 +01:00
domain_audit.h Include pid namespace inode in LXC audit messages 2013-03-07 19:43:53 +00:00
domain_conf.c conf: introduce spiceport chardev backend 2014-02-11 13:43:55 +01:00
domain_conf.h conf: introduce spiceport chardev backend 2014-02-11 13:43:55 +01:00
domain_event.c event: pass reason for PM events 2014-02-12 10:48:16 -07:00
domain_event.h event: pass reason for PM events 2014-02-12 10:48:16 -07:00
domain_nwfilter.c Convert 'int i' to 'size_t i' in src/conf/ files 2013-07-10 17:40:13 +01:00
domain_nwfilter.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
interface_conf.c conf: Always use VIR_ERR_CONFIG_UNSUPPORTED on enumFromString() failures 2014-01-16 11:09:43 +01:00
interface_conf.h Get rid of shadowed booleans 2013-10-22 15:50:47 +01:00
netdev_bandwidth_conf.c Adapt to VIR_ALLOC and virAsprintf in src/conf/* 2013-07-10 11:07:31 +02:00
netdev_bandwidth_conf.h Rename xml.{c,h} to virxml.{c,h} 2012-12-21 11:19:50 +00:00
netdev_vlan_conf.c conf: Always use VIR_ERR_CONFIG_UNSUPPORTED on enumFromString() failures 2014-01-16 11:09:43 +01:00
netdev_vlan_conf.h maint: avoid 'const fooPtr' in conf 2013-10-14 14:34:38 -06:00
netdev_vport_profile_conf.c conf: Always use VIR_ERR_CONFIG_UNSUPPORTED on enumFromString() failures 2014-01-16 11:09:43 +01:00
netdev_vport_profile_conf.h Rename xml.{c,h} to virxml.{c,h} 2012-12-21 11:19:50 +00:00
network_conf.c virNetworkLoadState: Disallow mangled 'floor' element 2014-02-10 19:26:16 +01:00
network_conf.h network: change default of forwardPlainNames to 'yes' 2014-02-04 12:00:26 +02:00
network_event.c event: prepare client to track domain callbackID 2014-02-12 10:48:15 -07:00
network_event.h event: move event filtering to daemon (regression fix) 2014-02-05 08:03:31 -07:00
node_device_conf.c conf: Always use VIR_ERR_CONFIG_UNSUPPORTED on enumFromString() failures 2014-01-16 11:09:43 +01:00
node_device_conf.h util: use size_t instead of unsigned int for num_virtual_functions 2013-11-08 14:31:11 +02:00
nwfilter_conf.c Push nwfilter update locking up to top level 2014-01-30 18:00:20 +00:00
nwfilter_conf.h Push nwfilter update locking up to top level 2014-01-30 18:00:20 +00:00
nwfilter_ipaddrmap.c Adapt to VIR_ALLOC and virAsprintf in src/conf/* 2013-07-10 11:07:31 +02:00
nwfilter_ipaddrmap.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
nwfilter_params.c maint: avoid 'const fooPtr' in nwfilter files 2013-10-14 13:13:18 -06:00
nwfilter_params.h maint: avoid 'const fooPtr' in nwfilter files 2013-10-14 13:13:18 -06:00
object_event_private.h event: prepare client to track domain callbackID 2014-02-12 10:48:15 -07:00
object_event.c event: prepare client to track domain callbackID 2014-02-12 10:48:15 -07:00
object_event.h event: add notion of remoteID for filtering client network events 2014-01-15 13:55:21 -07:00
secret_conf.c conf: Always use VIR_ERR_CONFIG_UNSUPPORTED on enumFromString() failures 2014-01-16 11:09:43 +01:00
secret_conf.h maint: avoid 'const fooPtr' in conf 2013-10-14 14:34:38 -06:00
snapshot_conf.c snapshot: Add support for specifying snapshot disk backing type 2014-01-29 12:56:35 +01:00
snapshot_conf.h snapshot: Add support for specifying snapshot disk backing type 2014-01-29 12:56:35 +01:00
storage_conf.c storage: Introduce internal pool support 2014-01-16 11:39:53 +01:00
storage_conf.h Add glusterfs to VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_POOL_TYPE 2014-02-07 10:26:46 +01:00
storage_encryption_conf.c conf: Always use VIR_ERR_CONFIG_UNSUPPORTED on enumFromString() failures 2014-01-16 11:09:43 +01:00
storage_encryption_conf.h Rename util.{c,h} to virutil.{c,h} 2012-12-21 11:19:49 +00:00
virchrdev.c Adapt to VIR_ALLOC and virAsprintf in src/conf/* 2013-07-10 11:07:31 +02:00
virchrdev.h conf: Add unix socket support to virChrdevOpen 2013-01-04 18:07:11 -07:00