Re: [RFC 1/3] hmp: avoid the nested event loop in handle_hmp_command()

2023-09-07 Thread Stefan Hajnoczi
On Thu, 7 Sept 2023 at 16:53, Dr. David Alan Gilbert wrote: > > * Stefan Hajnoczi (stefa...@gmail.com) wrote: > > On Thu, 7 Sept 2023 at 10:07, Dr. David Alan Gilbert > > wrote: > > > > > > * Stefan Hajnoczi (stefa...@redhat.com) wrote: > > > > On Thu, Sep 07, 2023 at 01:06:39AM +, Dr. David

Re: [RFC 1/3] hmp: avoid the nested event loop in handle_hmp_command()

2023-09-07 Thread Dr. David Alan Gilbert
* Stefan Hajnoczi (stefa...@gmail.com) wrote: > On Thu, 7 Sept 2023 at 10:07, Dr. David Alan Gilbert wrote: > > > > * Stefan Hajnoczi (stefa...@redhat.com) wrote: > > > On Thu, Sep 07, 2023 at 01:06:39AM +, Dr. David Alan Gilbert wrote: > > > > * Stefan Hajnoczi (stefa...@redhat.com) wrote: >

Re: [RFC 1/3] hmp: avoid the nested event loop in handle_hmp_command()

2023-09-07 Thread Stefan Hajnoczi
On Thu, 7 Sept 2023 at 10:07, Dr. David Alan Gilbert wrote: > > * Stefan Hajnoczi (stefa...@redhat.com) wrote: > > On Thu, Sep 07, 2023 at 01:06:39AM +, Dr. David Alan Gilbert wrote: > > > * Stefan Hajnoczi (stefa...@redhat.com) wrote: > > > > Coroutine HMP commands currently run to completion

Re: [RFC 1/3] hmp: avoid the nested event loop in handle_hmp_command()

2023-09-07 Thread Dr. David Alan Gilbert
* Stefan Hajnoczi (stefa...@redhat.com) wrote: > On Thu, Sep 07, 2023 at 01:06:39AM +, Dr. David Alan Gilbert wrote: > > * Stefan Hajnoczi (stefa...@redhat.com) wrote: > > > Coroutine HMP commands currently run to completion in a nested event > > > loop with the Big QEMU Lock (BQL) held. The ca

Re: [RFC 1/3] hmp: avoid the nested event loop in handle_hmp_command()

2023-09-07 Thread Stefan Hajnoczi
On Thu, Sep 07, 2023 at 01:06:39AM +, Dr. David Alan Gilbert wrote: > * Stefan Hajnoczi (stefa...@redhat.com) wrote: > > Coroutine HMP commands currently run to completion in a nested event > > loop with the Big QEMU Lock (BQL) held. The call_rcu thread also uses > > the BQL and cannot process

Re: [RFC 1/3] hmp: avoid the nested event loop in handle_hmp_command()

2023-09-06 Thread Dr. David Alan Gilbert
* Stefan Hajnoczi (stefa...@redhat.com) wrote: > Coroutine HMP commands currently run to completion in a nested event > loop with the Big QEMU Lock (BQL) held. The call_rcu thread also uses > the BQL and cannot process work while the coroutine monitor command is > running. A deadlock occurs when mo

[RFC 1/3] hmp: avoid the nested event loop in handle_hmp_command()

2023-09-06 Thread Stefan Hajnoczi
Coroutine HMP commands currently run to completion in a nested event loop with the Big QEMU Lock (BQL) held. The call_rcu thread also uses the BQL and cannot process work while the coroutine monitor command is running. A deadlock occurs when monitor commands attempt to wait for call_rcu work to fin