qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [Bug 1087114] Re: assertion "QLIST_EMPTY(&bs->tracked_r


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [Bug 1087114] Re: assertion "QLIST_EMPTY(&bs->tracked_requests)" failed
Date: Thu, 27 Dec 2012 12:48:56 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0

Il 27/12/2012 05:26, Brad Smith ha scritto:
> Paolo,
> 
> As you wrote the fallback code which is used when sem_timedwait() is
> missing could you please take a look at this when you have some time? I
> can test any patches you might come up with.

Can you try this:

diff --git a/util/qemu-thread-posix.c b/util/qemu-thread-posix.c
index 7be292e..17f2d7c 100644
--- a/util/qemu-thread-posix.c
+++ b/util/qemu-thread-posix.c
@@ -213,6 +213,7 @@ int qemu_sem_timedwait(QemuSemaphore *sem, int ms)
     while (sem->count < 0) {
         rc = pthread_cond_timedwait(&sem->cond, &sem->lock, &ts);
         if (rc == ETIMEDOUT) {
+            ++sem->count;
             break;
         }
         if (rc != 0) {

and if it passes, post it?  I'll be very sparsely online until Jan 8th.

Signed-off-by: Paolo Bonzini <address@hidden>

Paolo



reply via email to

[Prev in Thread] Current Thread [Next in Thread]