6#ifndef NEXUS_IO_ETHERNET_H
7#define NEXUS_IO_ETHERNET_H
13#define NX_ETH_FRAME_MIN 14U
14#define NX_ETH_FRAME_MAX 1514U
15#define NX_ETH_RX_STORAGE_MIN 1518U
16#define NX_ETH_RX_CRC 1U
17#define NX_ETH_RX_LENGTH 2U
18#define NX_ETH_RX_FRAGMENT 4U
19#define NX_ETH_RX_UNSUPPORTED 8U
20#define NX_ETH_RX_DMA_ERROR 16U
21#define NX_ETH_RX_BACKPRESSURE 32U
172 uint8_t syscall_ceiling);
nx_result_t nx_eth_port_stop(const nx_eth_port_t *port)
Close admission and withdraw MAC/DMA/IRQ sources with readback.
nx_result_t nx_eth_port_cancel(const nx_eth_port_t *port, nx_eth_tx_request_t *request)
Close TX admission and drain the shared TX engine without replay.
nx_result_t nx_eth_port_release(const nx_eth_port_t *port, const nx_eth_rx_frame_t *frame)
Final consumer access; stale, foreign and double releases reject.
nx_result_t nx_eth_port_submit(const nx_eth_port_t *port, nx_eth_tx_request_t *request)
Admit one frame into caller-owned hardware descriptors.
nx_result_t nx_eth_port_service(const nx_eth_port_t *port)
Task-owner bounded progress; no worker, lock, pool or wait.
nx_result_t nx_eth_port_state(const nx_eth_port_t *port, nx_eth_state_t *state)
Copy latched instance/link/error facts; output is not retained.
nx_result_t nx_eth_port_acquire(const nx_eth_port_t *port, nx_eth_rx_frame_t *frame)
Task-consumer complete-frame loan; EMPTY creates no borrow.
nx_result_t nx_eth_tx_prepare(nx_eth_tx_request_t *request, const void *data, size_t length, nx_time_us_t deadline)
Prepare an initialized, unborrowed request and its immutable frame.
nx_result_t nx_eth_port_apply_link(const nx_eth_port_t *port, const nx_eth_link_t *link)
Apply external PHY observations, not auto-negotiate or invent link.
nx_result_t nx_eth_port_attach_wake(const nx_eth_port_t *port, const nx_irq_wake_t *wake, uint8_t syscall_ceiling)
Bind an optional borrowed hint after actual IRQ-policy validation.
Caller-owned admission, borrow, settlement and stable cancellation.
nx_result_t
Operation result; success at submission means admission only.
Observed PHY fact, supplied explicitly by the external link owner.
nx_result_t(* service)(void *)
nx_result_t(* attach_wake)(void *, const nx_irq_wake_t *, uint8_t)
nx_result_t(* apply_link)(void *, const nx_eth_link_t *)
nx_result_t(* stop)(void *)
nx_result_t(* cancel)(void *, nx_eth_tx_request_t *)
nx_result_t(* release)(void *, const nx_eth_rx_frame_t *)
nx_result_t(* submit)(void *, nx_eth_tx_request_t *)
nx_result_t(* acquire)(void *, nx_eth_rx_frame_t *)
nx_result_t(* state)(void *, nx_eth_state_t *)
Complete immutable frame; release requires this exact incarnation.
nx_time_us_t timestamp_us
Latched facts survive receive backpressure and failed wake hints.
uint64_t unavailable_events
Caller-owned immutable contiguous frame, excluding its hardware FCS.
Optional immutable wake target borrowed by an IRQ provider.
Caller-owned request metadata, without payload or callbacks.
uint64_t nx_time_us_t
Microseconds in one boot/clock domain; no wall-clock semantics.
Explicit borrowed IRQ wake target and syscall-ceiling check.