pub struct StreamingMap<T: DmaPod> { /* private fields */ }Implementations§
Source§impl<T: DmaPod> StreamingMap<T>
impl<T: DmaPod> StreamingMap<T>
pub fn dma_addr(&self) -> DmaAddr
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
pub fn bytes_len(&self) -> usize
pub fn read_cpu(&self, index: usize) -> Option<T>
pub fn set_cpu(&mut self, index: usize, value: T)
pub fn copy_from_slice_cpu(&mut self, src: &[T])
pub fn write_with_cpu<R>( &mut self, len: usize, f: impl FnOnce(&mut [T]) -> R, ) -> R
pub fn read_with_cpu<R>(&self, len: usize, f: impl FnOnce(&[T]) -> R) -> R
pub fn to_vec_cpu(&self) -> Vec<T>
pub fn sync_for_device(&self, offset: usize, size: usize)
pub fn sync_for_cpu(&self, offset: usize, size: usize)
pub fn sync_for_device_all(&self)
pub fn sync_for_cpu_all(&self)
pub fn prepare_for_device(&self, offset: usize, size: usize)
pub fn prepare_for_device_all(&self)
pub fn complete_for_cpu(&self, offset: usize, size: usize)
pub fn complete_for_cpu_all(&self)
pub fn write_for_device<R>( &mut self, len: usize, f: impl FnOnce(&mut [T]) -> R, ) -> R
pub fn read_from_device<R>(&self, len: usize, f: impl FnOnce(&[T]) -> R) -> R
pub fn bounce_ptr(&self) -> Option<NonNull<u8>>
Trait Implementations§
Source§impl<T: DmaPod> Drop for StreamingMap<T>
impl<T: DmaPod> Drop for StreamingMap<T>
impl<T: DmaPod + Send> Send for StreamingMap<T>
Auto Trait Implementations§
impl<T> !RefUnwindSafe for StreamingMap<T>
impl<T> !Sync for StreamingMap<T>
impl<T> !UnwindSafe for StreamingMap<T>
impl<T> Freeze for StreamingMap<T>
impl<T> Unpin for StreamingMap<T>
impl<T> UnsafeUnpin for StreamingMap<T>
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