pub struct MemTransactionDesc {
pub sender_id: u16,
pub mem_region_attr: MemRegionAttributes,
pub flags: MemTransactionFlags,
pub handle: Handle,
pub tag: u64,
}Expand description
Memory transaction decriptor. Used by an Owner/Lender and a Borrower/Receiver in a transaction to donate, lend or share a memory region.
Fields§
§sender_id: u16§mem_region_attr: MemRegionAttributes§flags: MemTransactionFlags§handle: Handle§tag: u64Implementations§
Source§impl MemTransactionDesc
impl MemTransactionDesc
Sourcepub fn pack(
&self,
constituents: &[ConstituentMemRegion],
access_descriptors: &[MemAccessPerm],
buf: &mut [u8],
) -> usize
pub fn pack( &self, constituents: &[ConstituentMemRegion], access_descriptors: &[MemAccessPerm], buf: &mut [u8], ) -> usize
Serialize a memory transaction descriptor and the related constituent memory region descriptors and endpoint memory access permission descriptors into a buffer.
Sourcepub fn unpack(
buf: &[u8],
) -> Result<(MemTransactionDesc, MemAccessPermIterator<'_>, Option<ConstituentMemRegionIterator<'_>>), Error>
pub fn unpack( buf: &[u8], ) -> Result<(MemTransactionDesc, MemAccessPermIterator<'_>, Option<ConstituentMemRegionIterator<'_>>), Error>
Deserialize a memory transaction descriptor from a buffer and return an interator of the related endpoint memory access permission descriptors and constituent memory region descriptors, if any.
Trait Implementations§
Source§impl Clone for MemTransactionDesc
impl Clone for MemTransactionDesc
Source§fn clone(&self) -> MemTransactionDesc
fn clone(&self) -> MemTransactionDesc
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MemTransactionDesc
impl Debug for MemTransactionDesc
Source§impl Default for MemTransactionDesc
impl Default for MemTransactionDesc
Source§fn default() -> MemTransactionDesc
fn default() -> MemTransactionDesc
Returns the “default value” for a type. Read more
Source§impl PartialEq for MemTransactionDesc
impl PartialEq for MemTransactionDesc
impl Eq for MemTransactionDesc
impl StructuralPartialEq for MemTransactionDesc
Auto Trait Implementations§
impl Freeze for MemTransactionDesc
impl RefUnwindSafe for MemTransactionDesc
impl Send for MemTransactionDesc
impl Sync for MemTransactionDesc
impl Unpin for MemTransactionDesc
impl UnwindSafe for MemTransactionDesc
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