pub struct TxMetadata {
pub id: TxId,
pub segment_count: usize,
pub len: usize,
pub offload_ip_header_checksum: bool,
pub offload_tcp_checksum: bool,
pub offload_udp_checksum: bool,
pub offload_tcp_segmentation: bool,
pub l3_protocol: L3Protocol,
pub l2_len: u8,
pub l3_len: u16,
pub l4_len: u8,
pub max_tcp_segment_size: u16,
}
Expand description
Transmit packet metadata.
Fields§
§id: TxId
The transmit ID.
segment_count: usize
The number of segments to follow.
len: usize
The total length of the packet in bytes.
offload_ip_header_checksum: bool
Offload IPv4 header checksum calculation.
l3_protocol, l2_len, and l3_len must be set.
offload_tcp_checksum: bool
Offload the TCP checksum calculation.
l3_protocol, l2_len, and l3_len must be set.
offload_udp_checksum: bool
Offload the UDP checksum calculation.
l3_protocol, l2_len, and l3_len must be set.
offload_tcp_segmentation: bool
Offload the TCP segmentation, allowing packets to be larger than the MTU.
l3_protocol, l2_len, l3_len, l4_len, and tcp_segment_size must be set.
l3_protocol: L3Protocol
The L3 protocol, needed when performing any of the offloads.
l2_len: u8
The length of the Ethernet frame header.
l3_len: u16
The length of the IP header.
l4_len: u8
The length of the TCP header.
max_tcp_segment_size: u16
The maximum TCP segment size, used for segmentation.
Trait Implementations§
Source§impl Clone for TxMetadata
impl Clone for TxMetadata
Source§fn clone(&self) -> TxMetadata
fn clone(&self) -> TxMetadata
Returns a copy 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 TxMetadata
impl Debug for TxMetadata
Auto Trait Implementations§
impl Freeze for TxMetadata
impl RefUnwindSafe for TxMetadata
impl Send for TxMetadata
impl Sync for TxMetadata
impl Unpin for TxMetadata
impl UnwindSafe for TxMetadata
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