Re: [RFC PATCH] cpus: split qemu_init_vcpu and delay vCPU thread creation

2024-05-30 Thread Alex Bennée
Pierrick Bouvier writes: > On 5/29/24 08:22, Alex Bennée wrote: >> This ensures we don't start the thread until cpu_common_realizefn has >> finished. This ensures that plugins will always run >> qemu_plugin_vcpu_init__async first before any other states. It doesn't >> totally eliminate the race t

Re: [RFC PATCH] cpus: split qemu_init_vcpu and delay vCPU thread creation

2024-05-30 Thread Pierrick Bouvier
On 5/29/24 08:22, Alex Bennée wrote: This ensures we don't start the thread until cpu_common_realizefn has finished. This ensures that plugins will always run qemu_plugin_vcpu_init__async first before any other states. It doesn't totally eliminate the race that plugin_cpu_update__locked has to wo

Re: [RFC PATCH] cpus: split qemu_init_vcpu and delay vCPU thread creation

2024-05-29 Thread Alex Bennée
Philippe Mathieu-Daudé writes: > Hi Alex, > > On 29/5/24 17:22, Alex Bennée wrote: >> This ensures we don't start the thread until cpu_common_realizefn has >> finished. This ensures that plugins will always run >> qemu_plugin_vcpu_init__async first before any other states. It doesn't >> totally e

Re: [RFC PATCH] cpus: split qemu_init_vcpu and delay vCPU thread creation

2024-05-29 Thread Philippe Mathieu-Daudé
Hi Alex, On 29/5/24 17:22, Alex Bennée wrote: This ensures we don't start the thread until cpu_common_realizefn has finished. This ensures that plugins will always run qemu_plugin_vcpu_init__async first before any other states. It doesn't totally eliminate the race that plugin_cpu_update__locked

[RFC PATCH] cpus: split qemu_init_vcpu and delay vCPU thread creation

2024-05-29 Thread Alex Bennée
This ensures we don't start the thread until cpu_common_realizefn has finished. This ensures that plugins will always run qemu_plugin_vcpu_init__async first before any other states. It doesn't totally eliminate the race that plugin_cpu_update__locked has to work around though. I found this while re