|
| From: | Sergey Fedorov |
| Subject: | Re: [Qemu-devel] [PATCH v5 07/18] qemu-thread: add simple test-and-set spinlock |
| Date: | Wed, 18 May 2016 21:21:26 +0300 |
| User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.7.2 |
On 14/05/16 06:34, Emilio G. Cota wrote:
> +static inline int qemu_spin_trylock(QemuSpin *spin)
> +{
> + if (atomic_test_and_set_acquire(&spin->value)) {
> + return -EBUSY;
Seems this should be:
return EBUSY;
> + }
> + return 0;
> +}
| [Prev in Thread] | Current Thread | [Next in Thread] |