Struct dma_boom::MappedDmaBufWo
source · pub struct MappedDmaBufWo<'a>(pub(crate) MappedDmaBuf<&'a mut DmaBuf>);
Expand description
A write-only Dmabuf mapped in memory. The underlying data gets cache-synced on creation and destruction.
Tuple Fields§
§0: MappedDmaBuf<&'a mut DmaBuf>
Implementations§
source§impl<'a> MappedDmaBufWo<'a>
impl<'a> MappedDmaBufWo<'a>
pub(crate) fn new( buf: &'a mut DmaBuf, len: usize, mapping_ptr: *mut u8, ) -> Result<Self, MapError>
sourcepub fn as_slice_mut(&mut self) -> &mut [u8] ⓘ
pub fn as_slice_mut(&mut self) -> &mut [u8] ⓘ
Access the underlying data mutably.
Data in this struct is cache-coherently guarded only for write access, so reading may give unexpected results.
Trait Implementations§
source§impl<'a> Debug for MappedDmaBufWo<'a>
impl<'a> Debug for MappedDmaBufWo<'a>
Auto Trait Implementations§
impl<'a> Freeze for MappedDmaBufWo<'a>
impl<'a> RefUnwindSafe for MappedDmaBufWo<'a>
impl<'a> !Send for MappedDmaBufWo<'a>
impl<'a> !Sync for MappedDmaBufWo<'a>
impl<'a> Unpin for MappedDmaBufWo<'a>
impl<'a> !UnwindSafe for MappedDmaBufWo<'a>
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