vm-virtio: Make all virtio devices potentially multi-threaded

Although only the block and net virtio devices can actually be multi
threaded (for now), handling them as special cases makes the code more
complex.

Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
This commit is contained in:
Samuel Ortiz
2020-01-27 13:56:05 +01:00
committed by Sebastien Boeuf
parent ac8e4b9cb6
commit f648f2856d
9 changed files with 43 additions and 17 deletions
+3 -1
View File
@@ -137,7 +137,9 @@ macro_rules! virtio_pausable_inner {
);
self.paused.store(false, Ordering::SeqCst);
if let Some(epoll_thread) = &self.epoll_thread {
epoll_thread.thread().unpark();
for i in 0..epoll_thread.len() {
epoll_thread[i].thread().unpark();
}
}
Ok(())