On Thu, 17 Mar 2022 at 11:57, Philippe Mathieu-Daudé
<philippe.mathieu.da...@gmail.com> wrote:
>
> From: Paolo Bonzini <pbonz...@redhat.com>
>
> Simplify the initialization dance by running qemu_init() in the main
> thread before the Cocoa event loop starts.  The cocoa_display_init()
> code that is post-applicationDidFinishLaunching: moves to the
> application delegate itself, and the secondary thread only runs
> the rest of qemu_main(), namely qemu_main_loop() and qemu_cleanup().
>
> This fixes a case where addRemovableDevicesMenuItems() calls
> qmp_query_block() while expecting the main thread to still hold
> the BQL.  The newly-introduced assertions in the block layer
> complain about this.
>
> Signed-off-by: Paolo Bonzini <pbonz...@redhat.com>
> Message-Id: <20220307151004.578069-1-pbonz...@redhat.com>
> [PMD: Fixed trivial build failures & rebased]
> Signed-off-by: Philippe Mathieu-Daudé <f4...@amsat.org>

Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>

(with or without the tweak you just mentioned for the
main_thread variable)

thanks
-- PMM

Reply via email to