[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] semaphore: fix a hangup problem under loadon Ne
From: |
Laszlo Ersek |
Subject: |
Re: [Qemu-devel] [PATCH] semaphore: fix a hangup problem under loadon NetBSD hosts. |
Date: |
Tue, 02 Jul 2013 17:47:27 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130621 Thunderbird/17.0.7 |
On 07/02/13 17:27, Izumi Tsutsui wrote:
> Laszlo Ersek wrote:
>> Conversely, the only time we need to send a signal is the 0->1 count
>> transition (*).
>
> Per comments from Soda, signals could be required even on count >0,
> if more than one threads are sleeping in qemu_cond_timedwait(),
> and more than one qemu_sem_post() are called at once, then
> the second qemu_sem_post() gets the mutex before sleeping threads
> in qemu_sem_timedwait().
You're right.
Laszlo