pub struct DmaAllocHandle { /* private fields */ }Implementations§
Source§impl DmaAllocHandle
impl DmaAllocHandle
Sourcepub unsafe fn new(
cpu_addr: NonNull<u8>,
dma_addr: DmaAddr,
layout: Layout,
) -> Self
pub unsafe fn new( cpu_addr: NonNull<u8>, dma_addr: DmaAddr, layout: Layout, ) -> Self
§Safety
cpu_addr must point to a live allocation described by layout, and
dma_addr must be the device-visible address for that allocation.
pub fn size(&self) -> usize
pub fn align(&self) -> usize
pub fn as_ptr(&self) -> NonNull<u8>
pub fn dma_addr(&self) -> DmaAddr
pub fn layout(&self) -> Layout
Trait Implementations§
Source§impl Clone for DmaAllocHandle
impl Clone for DmaAllocHandle
Source§fn clone(&self) -> DmaAllocHandle
fn clone(&self) -> DmaAllocHandle
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for DmaAllocHandle
Source§impl Debug for DmaAllocHandle
impl Debug for DmaAllocHandle
impl Eq for DmaAllocHandle
Source§impl Hash for DmaAllocHandle
impl Hash for DmaAllocHandle
Source§impl PartialEq for DmaAllocHandle
impl PartialEq for DmaAllocHandle
Source§fn eq(&self, other: &DmaAllocHandle) -> bool
fn eq(&self, other: &DmaAllocHandle) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for DmaAllocHandle
Auto Trait Implementations§
impl !Send for DmaAllocHandle
impl !Sync for DmaAllocHandle
impl Freeze for DmaAllocHandle
impl RefUnwindSafe for DmaAllocHandle
impl Unpin for DmaAllocHandle
impl UnsafeUnpin for DmaAllocHandle
impl UnwindSafe for DmaAllocHandle
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