[libvirt] [PATCH 08/10] Only call SetMemoryStatsPeriod for virtio memballoon
John Ferlan
jferlan at redhat.com
Fri Jun 5 12:07:08 UTC 2015
On 06/05/2015 07:58 AM, John Ferlan wrote:
>
>
> On 06/04/2015 09:58 AM, Ján Tomko wrote:
>> ---
>> src/qemu/qemu_process.c | 4 +++-
>> 1 file changed, 3 insertions(+), 1 deletion(-)
>>
>> diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c
>> index 7f154f0..64ee049 100644
>> --- a/src/qemu/qemu_process.c
>> +++ b/src/qemu/qemu_process.c
>> @@ -5517,7 +5517,9 @@ int qemuProcessAttach(virConnectPtr conn ATTRIBUTE_UNUSED,
>> if (running) {
>> virDomainObjSetState(vm, VIR_DOMAIN_RUNNING,
>> VIR_DOMAIN_RUNNING_UNPAUSED);
>> - if (vm->def->memballoon && vm->def->memballoon->period) {
>> + if (vm->def->memballoon &&
>> + vm->def->memballoon->model == VIR_DOMAIN_MEMBALLOON_MODEL_VIRTIO &&
>> + vm->def->memballoon->period) {
>
> Setting a period == 0 means to disable collection IIRC... yep, true from
> the man page...
>
> ACK if you remove the vm->def->memballoon->period condition
>
> John
>
>
oh... hmmm brain slower than eyes and fingers... qemuProcessAttach...
nevermind - no need to remove...
John
>
>> qemuDomainObjEnterMonitor(driver, vm);
>> qemuMonitorSetMemoryStatsPeriod(priv->mon,
>> vm->def->memballoon->period);
>>
>
> --
> libvir-list mailing list
> libvir-list at redhat.com
> https://www.redhat.com/mailman/listinfo/libvir-list
>
More information about the libvir-list
mailing list