Skip to content

Commit 9d7ec62

Browse files
committed
Add method to get table size for MSI-X capabilities
1 parent 3c3ad5c commit 9d7ec62

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/capability/msix.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use super::{PciCapabilityAddress, TriggerMode};
1+
use super::PciCapabilityAddress;
22
use crate::ConfigRegionAccess;
33
use bit_field::BitField;
44

@@ -53,6 +53,10 @@ impl MsixCapability {
5353
self.table & !0b111
5454
}
5555

56+
pub fn table_size(&self) -> u16 {
57+
self.table_size
58+
}
59+
5660
pub fn pba_bar(&self) -> u8 {
5761
self.pba.get_bits(0..3) as u8
5862
}

0 commit comments

Comments
 (0)