From: Pierrick Bouvier Date: Fri, 4 Apr 2025 03:20:26 +0000 (-0700) Subject: plugins/loader: fix deadlock when resetting/uninstalling a plugin X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=c07cd110a1824e2d046581af7375f16dac26e96f;p=people%2Faperard%2Fqemu-dm.git plugins/loader: fix deadlock when resetting/uninstalling a plugin Reported and fixed by Dmitry Kurakin. Fixes: https://gitlab.com/qemu-project/qemu/-/issues/2901 Signed-off-by: Pierrick Bouvier Message-Id: <20250404032027.430575-2-pierrick.bouvier@linaro.org> Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé --- diff --git a/plugins/loader.c b/plugins/loader.c index 7523d554f0..0d6e082e17 100644 --- a/plugins/loader.c +++ b/plugins/loader.c @@ -370,7 +370,7 @@ static void plugin_reset_destroy(struct qemu_plugin_reset_data *data) { qemu_rec_mutex_lock(&plugin.lock); plugin_reset_destroy__locked(data); - qemu_rec_mutex_lock(&plugin.lock); + qemu_rec_mutex_unlock(&plugin.lock); } static void plugin_flush_destroy(CPUState *cpu, run_on_cpu_data arg)