RE: [PATCH] multifd: ensure multifd threads are terminated before cleanup params

2022-02-21 Thread Wangxin (Alexander)
Ping. > > In multifd_save_cleanup(), we terminate all multifd threads and destroy > the 'p->mutex', while the mutex may still be held by multifd send thread, > this causes qemu to crash. > > It's because the multifd_send_thread maybe scheduled out after setting > 'p->running' to false. To reprod

[PATCH] multifd: ensure multifd threads are terminated before cleanup params

2022-02-12 Thread Wang Xin via
In multifd_save_cleanup(), we terminate all multifd threads and destroy the 'p->mutex', while the mutex may still be held by multifd send thread, this causes qemu to crash. It's because the multifd_send_thread maybe scheduled out after setting 'p->running' to false. To reproduce the problem, we pu