mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2025-02-05 18:20:34 +00:00
Revert "devices: virtio: disable MSI-X for block and net"
Re-enable MSI-X for virtio-blk and virtio-net now that the underlying
issue causing hangs at startup has been fixed (CL:1917495).
BUG=chromium:1019986
TEST=Boot Termina on nami
This reverts commit 85858f580e
.
Change-Id: I5a5e197243a16aee2b2aaf3145a1180749b097b2
Signed-off-by: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/1918261
Reviewed-by: Zide Chen <zide.chen@intel.com>
Reviewed-by: Zach Reizner <zachr@chromium.org>
Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
parent
2a9e620f9a
commit
1de388ae02
4 changed files with 18 additions and 0 deletions
|
@ -29,6 +29,7 @@ use super::{
|
|||
|
||||
const QUEUE_SIZE: u16 = 256;
|
||||
const QUEUE_SIZES: &[u16] = &[QUEUE_SIZE];
|
||||
const NUM_MSIX_VECTORS: u16 = 2;
|
||||
const SECTOR_SHIFT: u8 = 9;
|
||||
const SECTOR_SIZE: u64 = 0x01 << SECTOR_SHIFT;
|
||||
const MAX_DISCARD_SECTORS: u32 = u32::MAX;
|
||||
|
@ -706,6 +707,10 @@ impl VirtioDevice for Block {
|
|||
TYPE_BLOCK
|
||||
}
|
||||
|
||||
fn msix_vectors(&self) -> u16 {
|
||||
NUM_MSIX_VECTORS
|
||||
}
|
||||
|
||||
fn queue_max_sizes(&self) -> &[u16] {
|
||||
QUEUE_SIZES
|
||||
}
|
||||
|
|
|
@ -25,6 +25,7 @@ use super::{Interrupt, Queue, Reader, VirtioDevice, Writer, TYPE_NET};
|
|||
const QUEUE_SIZE: u16 = 256;
|
||||
const NUM_QUEUES: usize = 2;
|
||||
const QUEUE_SIZES: &[u16] = &[QUEUE_SIZE, QUEUE_SIZE];
|
||||
const NUM_MSIX_VECTORS: u16 = NUM_QUEUES as u16;
|
||||
|
||||
#[derive(Debug)]
|
||||
pub enum NetError {
|
||||
|
@ -406,6 +407,10 @@ where
|
|||
TYPE_NET
|
||||
}
|
||||
|
||||
fn msix_vectors(&self) -> u16 {
|
||||
NUM_MSIX_VECTORS
|
||||
}
|
||||
|
||||
fn queue_max_sizes(&self) -> &[u16] {
|
||||
QUEUE_SIZES
|
||||
}
|
||||
|
|
|
@ -150,6 +150,10 @@ where
|
|||
TYPE_NET
|
||||
}
|
||||
|
||||
fn msix_vectors(&self) -> u16 {
|
||||
NUM_MSIX_VECTORS
|
||||
}
|
||||
|
||||
fn queue_max_sizes(&self) -> &[u16] {
|
||||
QUEUE_SIZES
|
||||
}
|
||||
|
|
|
@ -112,6 +112,10 @@ impl VirtioDevice for Vsock {
|
|||
TYPE_VSOCK
|
||||
}
|
||||
|
||||
fn msix_vectors(&self) -> u16 {
|
||||
NUM_MSIX_VECTORS
|
||||
}
|
||||
|
||||
fn queue_max_sizes(&self) -> &[u16] {
|
||||
QUEUE_SIZES
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue