[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v4 1/4] seqlock: introduce read-write seqlock
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH v4 1/4] seqlock: introduce read-write seqlock |
Date: |
Tue, 24 Sep 2013 10:13:20 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130805 Thunderbird/17.0.8 |
Il 24/09/2013 07:33, liu ping fan ha scritto:
> On Mon, Sep 23, 2013 at 2:21 PM, Jan Kiszka <address@hidden> wrote:
>> On 2013-09-22 10:11, Liu Ping Fan wrote:
>>> This lets the read-side access run outside the BQL.
>>
>> In fact, not only BQL. Didn't the original commit provide a changlog
>> about the content of this patch? Otherwise, briefly describe use cases
>> and maybe the typical invocation pattern.
>>
> Original commit provide no changelog (right? Paolo, if I do miss the
> latest one in your tree).
Indeed I had never written one.
> What about the commit log like:
>
> Seqlock implementation for QEMU. Usage idiom
> reader:
> seqlock_read_begin()
> do{
> }while(seqlock_read_try())
>
> writer:
> seqlock_write_lock()
> ...
> seqlock_write_unlock()
>
> initialization:
> seqlock_init(QemuSeqLock *sl, QemuMutex *mutex)
> where mutex could be NULL if the caller has provided extra lock
> protection for seqlock_write_lock.
replace "has provided" with "will provide". Otherwise looks good.
Paolo
- [Qemu-devel] [PATCH v4 0/4] timers thread-safe stuff, Liu Ping Fan, 2013/09/22
- [Qemu-devel] [PATCH v4 1/4] seqlock: introduce read-write seqlock, Liu Ping Fan, 2013/09/22
- [Qemu-devel] [PATCH v4 2/4] timer: protect timers_state's clock with seqlock, Liu Ping Fan, 2013/09/22
- [Qemu-devel] [PATCH v4 3/4] qemu-thread: add QemuEvent, Liu Ping Fan, 2013/09/22
- [Qemu-devel] [PATCH v4 4/4] timer: make qemu_clock_enable sync between disable and timer's cb, Liu Ping Fan, 2013/09/22