pub struct MappedOwningPciRegion { /* private fields */ }Expand description
A memory-mapped OwningPciRegion. This is also a PciRegion. Dropping this unmaps the
region.
Implementations§
Source§impl MappedOwningPciRegion
impl MappedOwningPciRegion
Sourcepub fn as_ptr(&self) -> *const u8
pub fn as_ptr(&self) -> *const u8
Returns a constant pointer to the beginning of the memory-mapped region.
Sourcepub fn as_mut_ptr(&self) -> *mut u8
pub fn as_mut_ptr(&self) -> *mut u8
Returns a mutable pointer to the beginning of the memory-mapped region.
Sourcepub fn len(&self) -> usize
pub fn len(&self) -> usize
The length of the region.
Unlike PciRegion::len, returns usize.
Trait Implementations§
Source§impl<'a> AsPciSubregion<'a> for &'a MappedOwningPciRegion
impl<'a> AsPciSubregion<'a> for &'a MappedOwningPciRegion
Source§fn as_subregion(&self) -> PciSubregion<'a>
fn as_subregion(&self) -> PciSubregion<'a>
Returns a
PciSubregion corresponding to self.Source§fn subregion(&self, range: impl RangeBounds<u64>) -> PciSubregion<'a>
fn subregion(&self, range: impl RangeBounds<u64>) -> PciSubregion<'a>
Returns a
PciSubregion corresponding to a range of self.Source§impl Debug for MappedOwningPciRegion
impl Debug for MappedOwningPciRegion
Source§impl Drop for MappedOwningPciRegion
impl Drop for MappedOwningPciRegion
Source§impl PciRegion for MappedOwningPciRegion
impl PciRegion for MappedOwningPciRegion
Source§fn permissions(&self) -> Permissions
fn permissions(&self) -> Permissions
Whether the region may be read, written, or both.
Source§fn read_bytes(&self, offset: u64, buffer: &mut [u8]) -> Result<()>
fn read_bytes(&self, offset: u64, buffer: &mut [u8]) -> Result<()>
Read from a contiguous range of the region into a byte buffer. Read more
impl Send for MappedOwningPciRegion
impl Sync for MappedOwningPciRegion
Auto Trait Implementations§
impl Freeze for MappedOwningPciRegion
impl !RefUnwindSafe for MappedOwningPciRegion
impl Unpin for MappedOwningPciRegion
impl !UnwindSafe for MappedOwningPciRegion
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more