#[non_exhaustive]pub struct ChecksumCapabilities {
pub ipv4: ChecksumOffload,
pub udp: ChecksumOffload,
pub tcp: ChecksumOffload,
pub icmpv4: ChecksumOffload,
pub icmpv6: ChecksumOffload,
}Expand description
Checksum offload capabilities per protocol direction.
The stack skips the offloaded work in software.
The default is no offload for every protocol: the stack computes and verifies everything itself.
A checksum the stack does not compute is written as zero, so that a device that fills it in finds a known value there.
The fields are the protocols with a checksum the stack handles. IGMP is not among them: its checksum is always computed and verified in software.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.ipv4: ChecksumOffloadOffload for the IPv4 header checksum.
udp: ChecksumOffloadOffload for the UDP checksum.
tcp: ChecksumOffloadOffload for the TCP checksum.
icmpv4: ChecksumOffloadOffload for the ICMPv4 checksum.
icmpv6: ChecksumOffloadOffload for the ICMPv6 checksum.
Implementations§
Source§impl ChecksumCapabilities
impl ChecksumCapabilities
Sourcepub fn all_offloaded() -> Self
pub fn all_offloaded() -> Self
Every checksum offloaded in both directions.
The stack computes and verifies nothing. Use this for devices where checksums don’t matter, like loopback.
Trait Implementations§
Source§impl Clone for ChecksumCapabilities
impl Clone for ChecksumCapabilities
Source§fn clone(&self) -> ChecksumCapabilities
fn clone(&self) -> ChecksumCapabilities
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more