[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 1/2] vhost-user: add a write-read lock
From: |
Peter Xu |
Subject: |
Re: [PATCH 1/2] vhost-user: add a write-read lock |
Date: |
Mon, 15 Jul 2024 09:27:38 -0400 |
On Mon, Jul 15, 2024 at 01:44:00PM +0530, Prasad Pandit wrote:
> On Thu, 11 Jul 2024 at 21:12, Peter Xu <peterx@redhat.com> wrote:
> > I apologize if I suggested WITH_QEMU_LOCK_GUARD when we talked.. I don't
> > remember which one I suggested, but in this case IIUC it'll be much easier
> > to review if you use the other sister function QEMU_LOCK_GUARD()
> > instead.. That should make the diff much, much less.
>
> * Yes, QEMU_LOCK_GUARD simplifies the diff, but it may extend the time
> for which lock is held, delaying other threads, is that okay?
I think it shouldn't be a major deal in most cases, if the extended cycles
only cover a bunch of instructions. In special case we can still use
WITH_QEMU_LOCK_GUARD, but I'd start with the simple first and only switch
if necessary.
Thanks,
--
Peter Xu
[PATCH 2/2] vhost: fail device start if iotlb update fails, Prasad Pandit, 2024/07/11
Re: [PATCH 0/2] Postcopy migration and vhost-user errors, Peter Xu, 2024/07/11