Re: [PATCH v2 5/5] blkdebug: protect rules and suspended_reqs with a lock

2021-05-11 Thread Paolo Bonzini
On 07/05/21 17:29, Eric Blake wrote: +qemu_mutex_lock(&s->lock); QLIST_FOREACH(r, &s->suspended_reqs, next) { if (!strcmp(r->tag, tag)) { +qemu_mutex_unlock(&s->lock); return true; } } +qemu_mutex_unlock(&s->lock); return fal

Re: [PATCH v2 5/5] blkdebug: protect rules and suspended_reqs with a lock

2021-05-11 Thread Emanuele Giuseppe Esposito
On 11/05/2021 10:37, Paolo Bonzini wrote: On 07/05/21 17:29, Eric Blake wrote: +    qemu_mutex_lock(&s->lock);   QLIST_FOREACH(r, &s->suspended_reqs, next) {   if (!strcmp(r->tag, tag)) { +    qemu_mutex_unlock(&s->lock);   return true;   }   } +   

Re: [PATCH v2 5/5] blkdebug: protect rules and suspended_reqs with a lock

2021-05-07 Thread Eric Blake
On 5/7/21 10:12 AM, Emanuele Giuseppe Esposito wrote: > Co-developed-by: Paolo Bonzini > Signed-off-by: Emanuele Giuseppe Esposito > --- > block/blkdebug.c | 32 +++- > 1 file changed, 31 insertions(+), 1 deletion(-) > > @@ -929,11 +956,14 @@ static bool > blkdebug

[PATCH v2 5/5] blkdebug: protect rules and suspended_reqs with a lock

2021-05-07 Thread Emanuele Giuseppe Esposito
Co-developed-by: Paolo Bonzini Signed-off-by: Emanuele Giuseppe Esposito --- block/blkdebug.c | 32 +++- 1 file changed, 31 insertions(+), 1 deletion(-) diff --git a/block/blkdebug.c b/block/blkdebug.c index dffd869b32..e92a35ccbb 100644 --- a/block/blkdebug.c +++ b/