|
From: | Halil Pasic |
Subject: | Re: [Qemu-devel] commit virtio: recalculate vq->inuse after migration might cause last_avail_idx vs. used_idx failure |
Date: | Thu, 15 Dec 2016 12:32:31 +0100 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 |
On 12/15/2016 11:52 AM, Dr. David Alan Gilbert wrote: >> We got a bugreport with this log for a live migration target. >> >> 2016-12-13T18:59:03.647309Z qemu-system-s390x: VQ 1 size 0x100 < >> last_avail_idx 0x2f76 - used_idx 0x762f > Is this actually an endian problem - 2f76 vs 762f ? > > Dave > Thanks! It seems you are right: static inline uint16_t vring_avail_idx(VirtQueue *vq) { hwaddr pa; pa = vq->vring.avail + offsetof(VRingAvail, idx); vq->shadow_avail_idx = virtio_lduw_phys(vq->vdev, pa); we should have an endiannes handling here before assigning shadow_avail_idx I guess return vq->shadow_avail_idx; } I will meditate a bit more on this and probably create a patch to fix it. What make me wonder is that according to the reports live migration usually works (ca 1% fails)... Can I credit you as reporter in case I end up making a fix? Halil
[Prev in Thread] | Current Thread | [Next in Thread] |