pub struct RxQueue { /* private fields */ }
Implementations
sourceimpl RxQueue
impl RxQueue
sourcepub unsafe fn consume(&mut self, descs: &mut [FrameDesc]) -> usize
pub unsafe fn consume(&mut self, descs: &mut [FrameDesc]) -> usize
Update descs
with information on which Umem
frames have
received packets. Returns the number of elements of descs
which have been updated.
The number of entries updated will be less than or equal to
the length of descs
. Entries will be updated sequentially
from the start of descs
until the end.
Once the contents of the consumed frames have been dealt with
and are no longer required, the frames should eventually be
added back on to either the FillQueue
or the TxQueue
.
Safety
The frames passed to this queue must belong to the same
Umem
that this RxQueue
instance is tied to.
sourcepub unsafe fn consume_one(&mut self, desc: &mut FrameDesc) -> usize
pub unsafe fn consume_one(&mut self, desc: &mut FrameDesc) -> usize
sourcepub unsafe fn poll_and_consume(
&mut self,
descs: &mut [FrameDesc],
poll_timeout: i32
) -> Result<usize>
pub unsafe fn poll_and_consume(
&mut self,
descs: &mut [FrameDesc],
poll_timeout: i32
) -> Result<usize>
sourcepub unsafe fn poll_and_consume_one(
&mut self,
desc: &mut FrameDesc,
poll_timeout: i32
) -> Result<usize>
pub unsafe fn poll_and_consume_one(
&mut self,
desc: &mut FrameDesc,
poll_timeout: i32
) -> Result<usize>
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for RxQueue
impl Send for RxQueue
impl !Sync for RxQueue
impl Unpin for RxQueue
impl UnwindSafe for RxQueue
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more