|
ConOpSys V2970
P004.07
ANVILEX control operating system
|
#include "lwip/opt.h"#include <string.h>#include <stdlib.h>#include "lwip/def.h"#include "lwip/ip_addr.h"#include "lwip/ip6_addr.h"#include "lwip/netif.h"#include "lwip/priv/tcp_priv.h"#include "lwip/udp.h"#include "lwip/priv/raw_priv.h"#include "lwip/snmp.h"#include "lwip/igmp.h"#include "lwip/etharp.h"#include "lwip/stats.h"#include "lwip/sys.h"#include "lwip/ip.h"#include "netif/ethernet.h"
Macros | |
| #define | NETIF_STATUS_CALLBACK(n) |
| #define | NETIF_LINK_CALLBACK(n) |
| #define | netif_index_to_num(index) ((index) - 1) |
| #define | NETIF_REPORT_TYPE_IPV4 0x01 |
| #define | NETIF_REPORT_TYPE_IPV6 0x02 |
Functions | |
| static void | netif_issue_reports (struct netif *netif, u8_t report_type) |
| void | netif_init (void) |
| err_t | netif_input (struct pbuf *p, struct netif *inp) |
| 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) |
| static void | netif_do_ip_addr_changed (const ip_addr_t *old_addr, const ip_addr_t *new_addr) |
| 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) |
Variables | |
| struct netif * | netif_list |
| struct netif * | netif_default |
| static u8_t | netif_num |
lwIP network interface abstraction
| #define netif_index_to_num | ( | index | ) | ((index) - 1) |
| #define NETIF_LINK_CALLBACK | ( | n | ) |
| #define NETIF_REPORT_TYPE_IPV4 0x01 |
| #define NETIF_REPORT_TYPE_IPV6 0x02 |
| #define NETIF_STATUS_CALLBACK | ( | n | ) |
| void netif_init | ( | void | ) |
References IP_ADDR6_HOST, netif_add(), netif_set_link_up(), netif_set_up(), NULL, and tcpip_input().
Referenced by lwip_init().


Forwards a received packet for input processing with ethernet_input() or ip_input() depending on netif flags. Don't call directly, pass to netif_add() and call netif->input(). Only works if the netif driver correctly sets NETIF_FLAG_ETHARP and/or NETIF_FLAG_ETHERNET flag!
References netif::flags, LWIP_ASSERT, LWIP_ASSERT_CORE_LOCKED, NETIF_FLAG_ETHARP, NETIF_FLAG_ETHERNET, and NULL.
Send ARP/IGMP/MLD/RS events, e.g. on link-up/netif-up or addr-change
References netif::flags, LWIP_ASSERT, NETIF_FLAG_ETHARP, NETIF_FLAG_IGMP, NETIF_FLAG_LINK_UP, NETIF_FLAG_UP, NETIF_REPORT_TYPE_IPV4, NETIF_REPORT_TYPE_IPV6, and NULL.
Referenced by netif_set_link_up(), and netif_set_up().

| struct netif* netif_default |
The default network interface.
Referenced by netif_add(), netif_remove(), and netif_set_default().
| struct netif* netif_list |
The list of network interfaces.
Referenced by netif_add(), and netif_remove().
|
static |
Referenced by netif_add().