Google is committed to advancing racial equity for Black communities. See how.

fuchsia.hardware.ethernet

PROTOCOLS

Device

Defined in fuchsia.hardware.ethernet/ethernet.fidl

Operation

Packets are transmitted by writing data into the IO buffer and writing a FifoEntry referencing that data (offset + length) into the tx fifo. When the driver is done accessing the data, a FifoEntry with the same cookie value (opaque to the driver) will be readable from the tx fifo.

Packets are received by writing a FifoEntry referencing an available buffer (offset + length) in the IO buffer. When a packet is received, a FifoEntry with the same cookie value (opaque to the driver) will be readable from the rx fifo. The offset field will be the same as was sent. The length field will reflect the actual size of the received packet. The flags field will indicate success or a specific failure condition.

IMPORTANT: The driver will not buffer response messages. It is the client's responsibility to ensure that there is space in the reply side of each fifo for each outstanding tx or rx request. The fifo sizes are returned along with the fifo handles from GetFifos().

See //zircon/system/public/zircon/device/ethernet.h for fifo entry layout and request / response message bits.

ConfigMulticastAddMac

Request

NameType
addr MacAddress

Response

NameType
status zx/status

ConfigMulticastDeleteMac

Request

NameType
addr MacAddress

Response

NameType
status zx/status

ConfigMulticastSetPromiscuousMode

Request

NameType
enabled bool

Response

NameType
status zx/status

ConfigMulticastTestFilter

Request

NameType

Response

NameType
status zx/status

DumpRegisters

Request

NameType

Response

NameType
status zx/status

GetFifos

Obtain a pair of fifos for queueing tx and rx operations

Request

NameType

Response

NameType
status zx/status
info Fifos?

GetInfo

Obtain information about device

Request

NameType

Response

NameType
info Info

GetStatus

Obtain the device status bits When these change, the signal SIGNAL_STATUS is asserted on the rx fifo. When these are read, the signal is deasserted.

Request

NameType

Response

NameType
device_status DeviceStatus

ListenStart

Start listening to the packets that we're transmitting as well as the packets we're receiving.

Request

NameType

Response

NameType
status zx/status

ListenStop

Stop listening to the packets that we're transmitting.

Request

NameType

Response

NameType

SetClientName

Request

NameType
name string[16]

Response

NameType
status zx/status

SetIOBuffer

Set the IO Buffer that will provide the data buffers for tx and rx operations

Request

NameType
h handle<vmo>

Response

NameType
status zx/status

SetPromiscuousMode

Request

NameType
enabled bool

Response

NameType
status zx/status

Start

Start transferring packets Start will not succeed (ZX_ERR_BAD_STATE) until the fifos have been obtained and an io buffer vmo has been registered.

Request

NameType

Response

NameType
status zx/status

Stop

Stop transferring packets

Request

NameType

Response

NameType

STRUCTS

Fifos

Defined in fuchsia.hardware.ethernet/ethernet.fidl

NameTypeDescriptionDefault
rx handle<fifo> No default
tx handle<fifo> No default
rx_depth uint32 No default
tx_depth uint32 No default

Info

Defined in fuchsia.hardware.ethernet/ethernet.fidl

NameTypeDescriptionDefault
features uint32 No default
mtu uint32 No default
mac MacAddress No default

MacAddress

Defined in fuchsia.hardware.ethernet/ethernet.fidl

NameTypeDescriptionDefault
octets uint8[6] No default

BITS

DeviceStatus

Type: uint32

NameValueDescription
ONLINE 1

CONSTANTS

NameValueTypeDescription
INFO_FEATURE_LOOPBACK 4 uint32
INFO_FEATURE_SYNTH 2 uint32
INFO_FEATURE_WLAN 1 uint32
MAX_CLIENT_NAME_LEN 15 uint32

Max client name length

SET_CLIENT_NAME_MAX_LEN 16 uint32

For compatibility with a past revision, allow one extra byte for an optional null-terminator.

SIGNAL_STATUS 16777216 uint32

Signal that is asserted on the RX fifo whenever the Device has a status change. This is ZX_USER_SIGNAL_0.