prf::net::eth namespace

Generic Ethernet-like control adapters and runtime helpers.

Generic Ethernet-like runtime helpers shared by USB and W5500 paths.

Classes

struct ArpFrameEvent
Parsed ARP frame metadata emitted by Ethernet-like runtime observer.
struct ArpIngressContext
Rich ARP ingress context provided to policy handlers.
class DhcpBindingRegistry
Generic registry-backed DHCP binding provider for Ethernet-like runtimes.
template<typename ConfigSectionT>
class EthernetControlCommands
Generic control adapter for Ethernet-like interfaces.
class EthInterfaceStatsProvider
Renders generic Ethernet-like interface status and counters for control API.
struct EthNetifBindingSnapshot
Current lwIP netif binding snapshot.
class EthNetifRuntime
Generic Ethernet lwIP netif runtime over injected L2 device.
struct EthNetifStatusSnapshot
Runtime status snapshot for diagnostics/control surfaces.
class EthRuntimeBindingSource
Adapter exposing EthNetifRuntime binding snapshot through IEthBindingSnapshotSource.
class IArpIngressHandler
Ingress ARP hook used for proxy/policy decisions.
class IEthBindingSnapshotSource
Read-only source of current lwIP binding snapshot for one interface.
class IEthernetControlCommands
Type-erased interface for Ethernet-like interface command adapters.
class IEthernetDevice
Abstraction of Ethernet-capable L2 device used by lwIP netif runtime.
class IEthNetifStatsSource
Read-only status source contract used by Ethernet-like control providers.

Enums

enum class ArpIngressHandlerResult: uint8_t { PassToLwip = 0u, Consumed }
Outcome of ingress ARP handler decision.

Functions

auto eth_linkoutput(struct netif*const iface, struct pbuf*const p) -> err_t
auto eth_netif_init_fn(struct netif*const iface) -> err_t
auto lwip_mtu_from_frame_bytes_no_fcs(const size_t frame_bytes_no_fcs) -> uint16_t constexpr
Converts backend frame contract value to lwIP L3 MTU.
auto parse_arp_frame_event(const uint8_t* frame, size_t frame_size, bool ingress, ArpFrameEvent* out) -> bool
Parses Ethernet II ARP frame into typed event payload.

Variables

uint16_t kDefaultFrameBytesNoFcs constexpr
Default maximum Ethernet frame size without FCS.
uint16_t kDefaultIpv4MtuBytes constexpr
Default IPv4 payload MTU for Ethernet links.
uint16_t kEthernetHeaderBytes constexpr
Ethernet II header length used by lwIP netif adapter.

Enum documentation

enum class prf::net::eth::ArpIngressHandlerResult: uint8_t

Outcome of ingress ARP handler decision.

Function documentation

err_t prf::net::eth::eth_linkoutput(struct netif*const iface, struct pbuf*const p)

err_t prf::net::eth::eth_netif_init_fn(struct netif*const iface)

uint16_t prf::net::eth::lwip_mtu_from_frame_bytes_no_fcs(const size_t frame_bytes_no_fcs) constexpr

Converts backend frame contract value to lwIP L3 MTU.

Parameters
frame_bytes_no_fcs Maximum full L2 Ethernet frame size (header + payload, excluding FCS) reported by HAL backend.
Returns IPv4 payload MTU used by lwIP.

bool prf::net::eth::parse_arp_frame_event(const uint8_t* frame, size_t frame_size, bool ingress, ArpFrameEvent* out)

Parses Ethernet II ARP frame into typed event payload.

Supported format is Ethernet/IPv4 ARP (htype=1, ptype=0x0800, hlen=6, plen=4) with standard 28-byte ARP payload.

Variable documentation

uint16_t prf::net::eth::kDefaultFrameBytesNoFcs constexpr

Default maximum Ethernet frame size without FCS.

The value is 1514 bytes = 14-byte Ethernet header + 1500-byte payload.

uint16_t prf::net::eth::kDefaultIpv4MtuBytes constexpr

Default IPv4 payload MTU for Ethernet links.

uint16_t prf::net::eth::kEthernetHeaderBytes constexpr

Ethernet II header length used by lwIP netif adapter.