ReactOS 0.4.16-dev-306-g647d351
|
Modules | |
IPv4 address handling | |
IPv6 address handling | |
Client data handling | |
Flags | |
MIB2 statistics | |
Classes | |
union | netif_ext_callback_args_t |
Macros | |
#define | netif_is_up(netif) (((netif)->flags & NETIF_FLAG_UP) ? (u8_t)1 : (u8_t)0) |
Typedefs | |
typedef u16_t | netif_nsc_reason_t |
typedef void(* | netif_ext_callback_fn) (struct netif *netif, netif_nsc_reason_t reason, const netif_ext_callback_args_t *args) |
Functions | |
struct netif * | netif_add_noaddr (struct netif *netif, void *state, netif_init_fn init, netif_input_fn input) |
struct netif * | netif_add (struct netif *netif, void *state, netif_init_fn init, netif_input_fn input) |
void | netif_remove (struct netif *netif) |
void | netif_set_default (struct netif *netif) |
void | netif_set_up (struct netif *netif) |
void | netif_set_down (struct netif *netif) |
void | netif_set_link_up (struct netif *netif) |
void | netif_set_link_down (struct netif *netif) |
u8_t | netif_name_to_index (const char *name) |
char * | netif_index_to_name (u8_t idx, char *name) |
struct netif * | netif_get_by_index (u8_t idx) |
struct netif * | netif_find (const char *name) |
typedef void(* netif_ext_callback_fn) (struct netif *netif, netif_nsc_reason_t reason, const netif_ext_callback_args_t *args) |
typedef u16_t netif_nsc_reason_t |
struct netif * netif_add | ( | struct netif * | netif, |
void * | state, | ||
netif_init_fn | init, | ||
netif_input_fn | input | ||
) |
Add a network interface to the list of lwIP netifs.
netif | a pre-allocated netif structure |
ipaddr | IP address for the new netif |
netmask | network mask for the new netif |
gw | default gateway IP address for the new netif |
state | opaque data passed to the new netif |
init | callback function that initializes the interface |
input | callback function that is called to pass ingress packets up in the protocol layer stack. It is recommended to use a function that passes the input directly to the stack (netif_input(), NO_SYS=1 mode) or via sending a message to TCPIP thread (tcpip_input(), NO_SYS=0 mode). These functions use netif flags NETIF_FLAG_ETHARP and NETIF_FLAG_ETHERNET to decide whether to forward to ethernet_input() or ip_input(). In other words, the functions only work when the netif driver is implemented correctly! Most members of struct netif should be be initialized by the netif init function = netif driver (init parameter of this function). IPv6: Don't forget to call netif_create_ip6_linklocal_address() after setting the MAC address in struct netif.hwaddr (IPv6 requires a link-local address). |
Definition at line 287 of file netif.c.
Referenced by default_netif_add(), lwip_fuzztest(), main(), netif_add_noaddr(), netif_init(), START_TEST(), TCPRegisterInterface(), and test_netif_add().
struct netif * netif_add_noaddr | ( | struct netif * | netif, |
void * | state, | ||
netif_init_fn | init, | ||
netif_input_fn | input | ||
) |
Add a network interface to the list of lwIP netifs.
Same as netif_add but without IPv4 addresses
Definition at line 250 of file netif.c.
Referenced by START_TEST().
Find a network interface by searching for its name
name | the name of the netif (like netif->name) plus concatenated number in ascii representation (e.g. 'en0') |
Definition at line 1755 of file netif.c.
Referenced by netif_name_to_index(), and START_TEST().
Return the interface for the netif index
idx | index of netif to find |
Definition at line 1730 of file netif.c.
Referenced by netif_index_to_name().
Remove a network interface from the list of lwIP netifs.
netif | the network interface to remove |
Definition at line 764 of file netif.c.
Referenced by default_netif_remove(), START_TEST(), TCPUnregisterInterface(), and test_netif_remove().
Set a network interface as the default network interface (used to output all packets for which no specific route is found)
netif | the default network interface |
Definition at line 849 of file netif.c.
Referenced by default_netif_add(), main(), netif_remove(), TCPUpdateInterfaceIPInformation(), and test_netif_add().
Bring an interface down, disabling any traffic processing.
Definition at line 949 of file netif.c.
Referenced by netif_remove(), START_TEST(), and TCPUpdateInterfaceIPInformation().
Called by a driver when its link goes down
Definition at line 1056 of file netif.c.
Referenced by main(), TCPUpdateInterfaceLinkStatus(), test_tcp_rto_timeout_impl(), test_tcp_rto_timeout_syn_sent_impl(), and test_tcp_zwp_timeout_impl().
Called by a driver when its link goes up
Definition at line 1018 of file netif.c.
Referenced by lwip_fuzztest(), main(), netif_init(), START_TEST(), and TCPUpdateInterfaceLinkStatus().
Bring an interface up, available for processing traffic.
Definition at line 871 of file netif.c.
Referenced by default_netif_add(), ip4_teardown(), lwip_fuzztest(), main(), netif_init(), START_TEST(), TCPUpdateInterfaceIPInformation(), and test_netif_add().