Loading...
Searching...
No Matches

Detailed Description

Files

file  eth.h
 Definitions for netdev common ethernet code.
 

Data Structures

struct  netdev_eth_rx_info_t
 Received frame status information for Ethernet devices. More...
 

Functions

int netdev_eth_get (netdev_t *dev, netopt_t opt, void *value, size_t max_len)
 Fallback function for netdev ethernet devices' _get function.
 
int netdev_eth_set (netdev_t *dev, netopt_t opt, const void *value, size_t value_len)
 Fallback function for netdev ethernet devices' _set function.
 

Flags for use in @ref netdev_eth_rx_info_t::flags

#define NETDEV_ETH_RX_INFO_FLAG_TIMESTAMP   (0x01)
 Timestamp valid.
 

Macro Definition Documentation

◆ NETDEV_ETH_RX_INFO_FLAG_TIMESTAMP

#define NETDEV_ETH_RX_INFO_FLAG_TIMESTAMP   (0x01)

Timestamp valid.

Definition at line 36 of file eth.h.

Function Documentation

◆ netdev_eth_get()

int netdev_eth_get ( netdev_t dev,
netopt_t  opt,
void *  value,
size_t  max_len 
)

Fallback function for netdev ethernet devices' _get function.

Supposed to be used by netdev drivers as default case.

Warning
Driver MUST implement NETOPT_ADDRESS case!
Parameters
[in]devnetwork device descriptor
[in]optoption type
[out]valuepointer to store the option's value in
[in]max_lenmaximal amount of byte that fit into value
Returns
number of bytes written to value
<0 on error

◆ netdev_eth_set()

int netdev_eth_set ( netdev_t dev,
netopt_t  opt,
const void *  value,
size_t  value_len 
)

Fallback function for netdev ethernet devices' _set function.

Parameters
[in]devnetwork device descriptor
[in]optoption type
[in]valuevalue to set
[in]value_lenthe length of value
Returns
number of bytes used from value
<0 on error