Struct xhci::extended_capabilities::List
source · pub struct List<M>where
M: Mapper + Clone,{ /* private fields */ }
Expand description
A struct to access xHCI Extended Capabilities.
Implementations§
source§impl<M> List<M>where
M: Mapper + Clone,
impl<M> List<M>where M: Mapper + Clone,
sourcepub unsafe fn new(
mmio_base: usize,
hccparams1: CapabilityParameters1,
mapper: M
) -> Option<Self>
pub unsafe fn new( mmio_base: usize, hccparams1: CapabilityParameters1, mapper: M ) -> Option<Self>
Creates a new accessor to the xHCI Extended Capabilities.
This method may return a None
value if the xHC does not support the xHCI Extended
Capabilities.
Safety
The caller must ensure that each of the xHCI Extended Capabilities is accessed only through the returned accessor.
Examples
let mut r = unsafe { xhci::Registers::new(MMIO_BASE, mapper.clone()) };
let mut l = unsafe {
extended_capabilities::List::new(MMIO_BASE, r.capability.hccparams1.read(), mapper)
};
Trait Implementations§
Auto Trait Implementations§
impl<M> RefUnwindSafe for List<M>where M: RefUnwindSafe,
impl<M> Send for List<M>where M: Send,
impl<M> Sync for List<M>where M: Sync,
impl<M> Unpin for List<M>where M: Unpin,
impl<M> UnwindSafe for List<M>where M: UnwindSafe,
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