qemu-e2k/include/sysemu
Akihiko Odaki bab6a301c5 ui/cocoa: Run qemu_init in the main thread
This work is based on:
https://patchew.org/QEMU/20220317125534.38706-1-philippe.mathieu.daude@gmail.com/

Simplify the initialization dance by running qemu_init() in the main
thread before the Cocoa event loop starts. The secondary thread only
runs only 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.

Overriding the code after calling qemu_init() is done by dynamically
replacing a function pointer variable, qemu_main when initializing
ui/cocoa, which unifies the static implementation of main() for
builds with ui/cocoa and ones without ui/cocoa.

Signed-off-by: Akihiko Odaki <akihiko.odaki@gmail.com>
Message-Id: <20220819132756.74641-2-akihiko.odaki@gmail.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2022-09-23 14:36:33 +02:00
..
accel-ops.h whpx: Added support for breakpoints and stepping 2022-04-06 14:31:55 +02:00
arch_init.h hw/loongarch: Add support loongson3 virt machine type. 2022-06-06 18:09:03 +00:00
balloon.h
block-backend-common.h block-backend-common.h: split function pointers in BlockDevOps 2022-03-04 18:18:26 +01:00
block-backend-global-state.h Clean up header guards that don't match their file name 2022-05-11 16:49:06 +02:00
block-backend-io.h block: Reorganize some declarations in block-backend-io.h 2022-07-12 12:14:56 +02:00
block-backend.h include/sysemu/block-backend: split header into I/O and global state (GS) API 2022-03-04 18:18:25 +01:00
blockdev.h include/sysemu/blockdev.h: global state API 2022-03-04 18:18:25 +01:00
cpu-throttle.h
cpu-timers.h replay: notify vCPU when BH is scheduled 2022-06-06 09:26:53 +02:00
cpus.h softmmu: List CPU types again 2022-03-16 08:43:10 +01:00
cryptodev-vhost-user.h
cryptodev-vhost.h
cryptodev.h crypto: Introduce RSA algorithm 2022-06-16 12:54:58 -04:00
device_tree.h
dirtylimit.h softmmu/dirtylimit: Implement virtual CPU throttle 2022-07-20 12:15:08 +01:00
dirtyrate.h migration/dirtyrate: Refactor dirty page rate calculation 2022-07-20 12:15:08 +01:00
dma.h hw/dma: Let dma_buf_read() / dma_buf_write() propagate MemTxResult 2022-01-18 12:56:29 +01:00
dump-arch.h
dump.h dump: Add more offset variables 2022-04-22 13:36:04 +04:00
event-loop-base.h util/event-loop-base: Introduce options to set the thread pool size 2022-05-09 10:43:23 +01:00
hax.h accel/hax: Introduce CONFIG_HAX_IS_POSSIBLE 2022-03-06 13:15:42 +01:00
hostmem.h
hvf_int.h
hvf.h
hw_accel.h accel: Introduce AccelOpsClass::cpus_are_resettable() 2022-03-06 13:15:42 +01:00
iothread.h Introduce event-loop-base abstract class 2022-05-09 10:43:23 +01:00
kvm_int.h
kvm.h accel/kvm/kvm-all: Introduce kvm_dirty_ring_size function 2022-07-20 12:15:08 +01:00
memory_mapping.h sysemu/memory_mapping: Become target-agnostic 2022-03-06 13:15:42 +01:00
numa.h
nvmm.h
os-posix.h block: move fcntl_setfl() 2022-05-03 15:17:53 +04:00
os-win32.h util/qemu-sockets: Enable unix socket support on Windows 2022-09-02 15:54:46 +04:00
qtest.h
replay.h replay: rewrite async event handling 2022-06-06 09:26:53 +02:00
reset.h
rng-random.h
rng.h
rtc.h rtc: Move RTC function prototypes to their own header 2022-01-28 14:29:46 +00:00
runstate-action.h
runstate.h whpx: Added support for breakpoints and stepping 2022-04-06 14:31:55 +02:00
seccomp.h
sysemu.h ui/cocoa: Run qemu_init in the main thread 2022-09-23 14:36:33 +02:00
tcg.h
tpm_backend.h
tpm_util.h
tpm.h sysemu: tpm: Add a stub function for TPM_IS_CRB 2022-05-06 09:06:50 -06:00
vhost-user-backend.h
watchdog.h
whpx.h
xen-mapcache.h
xen.h