audio/hda: Fix migration
PATCH 1/1 audio/hda: Fix migration
From: "Dr. David Alan Gilbert" <[email protected]>
Fix outgoing migration which was crashing in vmstate_hda_audio_stream_buf_needed, I think the problem is that we have room for upto 4 streams in the array but only use 2, when we come to try and save the state of the unused streams we hit st->state == NULL.
--- hw/audio/hda-codec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
hw/audio/hda-codec.c +1 -1
@@ -786,7 +786,7 @@ static void hda_audio_reset(DeviceState *dev)static bool vmstate_hda_audio_stream_buf_needed (void *opaque) {HDAAudioStream *st = opaque; -return st->state->use_timer; +return st->state && st->state->use_timer; }static const VMStateDescription vmstate_hda_audio_stream_buf = {
Signature · 1 line
2.17.1
Quoted 8 lines · Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" <[email protected]>
Fix outgoing migration which was crashing in
vmstate_hda_audio_stream_buf_needed, I think the problem is that we have room for upto 4 streams in the array but only use 2, when we come to try and save the state of the unused streams we hitst->state== NULL.
Quoted 5 lines
Fixes 280c1e1cdb24d80ecdfcSigned-off-by Dr. David Alan Gilbert <[email protected]>--- hw/audio/hda-codec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Regards,
Daniel
Signature · 3 lines
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
Quoted 10 lines · Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" <[email protected]>
Fix outgoing migration which was crashing in
vmstate_hda_audio_stream_buf_needed, I think the problem is that we have room for upto 4 streams in the array but only use 2, when we come to try and save the state of the unused streams we hitst->state== NULL.Fixes 280c1e1cdb24d80ecdfcSigned-off-by Dr. David Alan Gilbert <[email protected]>
Quoted 10 lines · * Dr. David Alan Gilbert (git) ([email protected]) wrote:
From: "Dr. David Alan Gilbert" <[email protected]>
Fix outgoing migration which was crashing in
vmstate_hda_audio_stream_buf_needed, I think the problem is that we have room for upto 4 streams in the array but only use 2, when we come to try and save the state of the unused streams we hitst->state== NULL.Fixes 280c1e1cdb24d80ecdfcSigned-off-by Dr. David Alan Gilbert <[email protected]>
Queued via migration
Quoted 21 lines
--- hw/audio/hda-codec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)hw/audio/hda-codec.c +1
-1@@ -786,7 +786,7 @@ static void hda_audio_reset(DeviceState *dev)static bool vmstate_hda_audio_stream_buf_needed (void *opaque) {HDAAudioStream *st = opaque; -return st->state->use_timer; +return st->state && st->state->use_timer; }static const VMStateDescription vmstate_hda_audio_stream_buf = {Signature · 1 line
2.17.1
--
Dr. David Alan Gilbert / [email protected] / Manchester, UK