<div dir="ltr"><div><div><div><div>Hi<br><br>After this patch, I still get wrong volume when migration finishes.<br><br></div>My test:<br>1) qemu-kvm -m 1024 -spice port=5967,disable-ticketing,seamless-migration=on -monitor stdio -vga qxl -device AC97 -snapshot ~/VirtualMachines/f21.img<br>2) SPICE_DEBUG=1 gtk/spicy -p 5967<br>3) qemu-kvm -m 1024 -spice port=5968,disable-ticketing,seamless-migration=on -vga qxl -device AC97 -snapshot ~/VirtualMachines/f21.img -monitor stdio -incoming tcp::4445<br></div>4) on 1) monitor:<br>client_migrate_info spice 127.0.0.1 5968<br>migrate -d tcp:localhost:4445<br></div>5) observe volume change in client after migration<br><br></div>Furthermore, how would this patch let the client sync with valid guest volume changes? Migration may take a while, the client could still be running the guest and volume control should keep working.<br><div><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Apr 24, 2015 at 12:27 PM, Victor Toso <span dir="ltr"><<a href="mailto:victortoso@redhat.com" target="_blank">victortoso@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">During migration we should not allow volume-changes. QEMU does it<br>
internally and it end up sending the current guest volume on migration.<br>
<br>
We track on the client all volume-changes that happen in the guest and<br>
we change the volume of the client application accordingly. But this<br>
volume-change on migration is not done by the user and should be<br>
ignored.<br>
<br>
Resolve: <a href="https://bugzilla.redhat.com/show_bug.cgi?id=1012868" target="_blank">https://bugzilla.redhat.com/show_bug.cgi?id=1012868</a><br>
---<br>
server/snd_worker.c | 16 ++++++++++++++++<br>
1 file changed, 16 insertions(+)<br>
<br>
diff --git a/server/snd_worker.c b/server/snd_worker.c<br>
index a1223b4..e1f70d1 100644<br>
--- a/server/snd_worker.c<br>
+++ b/server/snd_worker.c<br>
@@ -1015,6 +1015,10 @@ SPICE_GNUC_VISIBLE void spice_server_playback_set_volume(SpicePlaybackInstance *<br>
if (!channel || nchannels == 0)<br>
return;<br>
<br>
+ if (red_client_during_migrate_at_target(channel->channel_client->client)) {<br>
+ spice_debug("Do not set playback volume during migration");<br>
+ return;<br>
+ }<br>
snd_playback_send_volume(playback_channel);<br>
}<br>
<br>
@@ -1029,6 +1033,10 @@ SPICE_GNUC_VISIBLE void spice_server_playback_set_mute(SpicePlaybackInstance *si<br>
if (!channel)<br>
return;<br>
<br>
+ if (red_client_during_migrate_at_target(channel->channel_client->client)) {<br>
+ spice_debug("Do not set playback mute during migration");<br>
+ return;<br>
+ }<br>
snd_playback_send_mute(playback_channel);<br>
}<br>
<br>
@@ -1270,6 +1278,10 @@ SPICE_GNUC_VISIBLE void spice_server_record_set_volume(SpiceRecordInstance *sin,<br>
if (!channel || nchannels == 0)<br>
return;<br>
<br>
+ if (red_client_during_migrate_at_target(channel->channel_client->client)) {<br>
+ spice_debug("Do not set record volume during migration");<br>
+ return;<br>
+ }<br>
snd_record_send_volume(record_channel);<br>
}<br>
<br>
@@ -1284,6 +1296,10 @@ SPICE_GNUC_VISIBLE void spice_server_record_set_mute(SpiceRecordInstance *sin, u<br>
if (!channel)<br>
return;<br>
<br>
+ if (red_client_during_migrate_at_target(channel->channel_client->client)) {<br>
+ spice_debug("Do not set record mute during migration");<br>
+ return;<br>
+ }<br>
snd_record_send_mute(record_channel);<br>
}<br>
<span class=""><font color="#888888"><br>
--<br>
2.1.0<br>
<br>
_______________________________________________<br>
Spice-devel mailing list<br>
<a href="mailto:Spice-devel@lists.freedesktop.org">Spice-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/spice-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/spice-devel</a><br>
</font></span></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature">Marc-André Lureau</div>
</div></div></div></div></div>