[libvirt] [PATCH v3 6/6] qemuDomainBlockJobImpl: utilize blockJob condition

Jiri Denemark jdenemar at redhat.com
Thu Feb 19 12:55:15 UTC 2015


On Fri, Feb 13, 2015 at 16:24:33 +0100, Michal Privoznik wrote:
> Instead of unlocking and locking the domain object every 50ms
> lets just wait on blockJob condition and run the loop body if and
> BLOCK_JOB even occurred.
> 
> Signed-off-by: Michal Privoznik <mprivozn at redhat.com>
> ---
> 
> This one, well, I still left the only monitor call as I'm not
> very familiar with this code so I don't know if it can be more
> optimized. But hey, the 50ms sleep is gone!

It seems the monitor call just checks for block job status, which seems
redundant since it should already be present in disk->mirrorState thanks
to the block job event handler.

Jirka




More information about the libvir-list mailing list