mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2024-10-02 11:35:46 +00:00
virtio-devices: Drop unused 'queue_evts' from VirtioCommon
Signed-off-by: Bo Chen <chen.bo@intel.com>
This commit is contained in:
parent
226a21811e
commit
3c26e9b741
@ -219,7 +219,6 @@ pub struct VirtioCommon {
|
|||||||
pub acked_features: u64,
|
pub acked_features: u64,
|
||||||
pub kill_evt: Option<EventFd>,
|
pub kill_evt: Option<EventFd>,
|
||||||
pub interrupt_cb: Option<Arc<dyn VirtioInterrupt>>,
|
pub interrupt_cb: Option<Arc<dyn VirtioInterrupt>>,
|
||||||
pub queue_evts: Option<Vec<EventFd>>,
|
|
||||||
pub pause_evt: Option<EventFd>,
|
pub pause_evt: Option<EventFd>,
|
||||||
pub paused: Arc<AtomicBool>,
|
pub paused: Arc<AtomicBool>,
|
||||||
pub paused_sync: Option<Arc<Barrier>>,
|
pub paused_sync: Option<Arc<Barrier>>,
|
||||||
@ -278,16 +277,6 @@ impl VirtioCommon {
|
|||||||
// but clone it to pass into the thread.
|
// but clone it to pass into the thread.
|
||||||
self.interrupt_cb = Some(interrupt_cb.clone());
|
self.interrupt_cb = Some(interrupt_cb.clone());
|
||||||
|
|
||||||
let mut tmp_queue_evts: Vec<EventFd> = Vec::new();
|
|
||||||
for (_, _, queue_evt) in queues.iter() {
|
|
||||||
// Save the queue EventFD as we need to return it on reset
|
|
||||||
// but clone it to pass into the thread.
|
|
||||||
tmp_queue_evts.push(queue_evt.try_clone().map_err(|e| {
|
|
||||||
error!("failed to clone queue EventFd: {}", e);
|
|
||||||
ActivateError::BadActivate
|
|
||||||
})?);
|
|
||||||
}
|
|
||||||
self.queue_evts = Some(tmp_queue_evts);
|
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user