Return a list of vring workers
Now that multiple worker threads can be run from the backend crate, it is important that each backend implementation can access every worker thread. Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
This commit is contained in:
parent
0e32b1242c
commit
d08282c080
1 changed files with 4 additions and 4 deletions
|
|
@ -191,8 +191,8 @@ impl<S: VhostUserBackend> VhostUserDaemon<S> {
|
|||
/// Retrieve the vring worker. This is necessary to perform further
|
||||
/// actions like registering and unregistering some extra event file
|
||||
/// descriptors.
|
||||
pub fn get_vring_worker(&self) -> Arc<VringWorker> {
|
||||
self.handler.lock().unwrap().get_vring_worker()
|
||||
pub fn get_vring_workers(&self) -> Vec<Arc<VringWorker>> {
|
||||
self.handler.lock().unwrap().get_vring_workers()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -545,8 +545,8 @@ impl<S: VhostUserBackend> VhostUserHandler<S> {
|
|||
})
|
||||
}
|
||||
|
||||
fn get_vring_worker(&self) -> Arc<VringWorker> {
|
||||
self.workers[0].clone()
|
||||
fn get_vring_workers(&self) -> Vec<Arc<VringWorker>> {
|
||||
self.workers.clone()
|
||||
}
|
||||
|
||||
fn vmm_va_to_gpa(&self, vmm_va: u64) -> VhostUserHandlerResult<u64> {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue