]> xenbits.xensource.com Git - people/liuw/libxenctrl-split/libvirt.git/commit
qemu: process: Improve update of maximum balloon state at startup
authorPeter Krempa <pkrempa@redhat.com>
Tue, 30 Jun 2015 14:31:24 +0000 (16:31 +0200)
committerPeter Krempa <pkrempa@redhat.com>
Tue, 14 Jul 2015 12:47:57 +0000 (14:47 +0200)
commitc212e0c77986b0592f63e02d9ecd816aaf7aac18
tree24fc82b8cb75dc7037f00c37de22055284303232
parent1cf25f633414dd844601965174b81bc9eb207d6b
qemu: process: Improve update of maximum balloon state at startup

In commit 641a145d73fdc3dd9350fd57b3d3247abf101c05 I've added code that
resets the balloon memory value to full size prior to resuming the vCPUs
since the size certainly was not reduced at that point.

Since qemuProcessStart is used also in code paths with already booted
up guests (migration, save/restore) the assumption is not entirely true
since the guest might already been running before.

This patch adds a function that queries the monitor rather than using
the full size since a balloon event would not be reissued in case we are
recovering a saved migration state.

Additionally the new function is used also when reconnecting to a VM
after libvirtd restart since we might have missed a few balloon events
while libvirtd was not running.
src/qemu/qemu_process.c