/hal_espressif-3.5.0/components/lwip/port/esp32/netif/ |
D | wlanif.c | 64 static void lwip_netif_wifi_free_rx_buffer(struct netif *netif, void *buf) in lwip_netif_wifi_free_rx_buffer() argument 66 esp_netif_t *esp_netif = esp_netif_get_handle_from_netif_impl(netif); in lwip_netif_wifi_free_rx_buffer() 79 low_level_init(struct netif *netif) in low_level_init() argument 82 netif->hwaddr_len = ETHARP_HWADDR_LEN; in low_level_init() 87 netif->mtu = 1500; in low_level_init() 91 netif->flags = NETIF_FLAG_BROADCAST | NETIF_FLAG_ETHARP | NETIF_FLAG_LINK_UP; in low_level_init() 95 netif->flags |= NETIF_FLAG_IGMP; in low_level_init() 101 netif->flags |= NETIF_FLAG_MLD6; in low_level_init() 106 netif->l2_buffer_free_notify = lwip_netif_wifi_free_rx_buffer; in low_level_init() 126 low_level_output(struct netif *netif, struct pbuf *p) in low_level_output() argument [all …]
|
D | ethernetif.c | 66 static void ethernet_free_rx_buf_l2(struct netif *netif, void *buf) in ethernet_free_rx_buf_l2() argument 77 static void ethernet_low_level_init(struct netif *netif) in ethernet_low_level_init() argument 80 netif->hwaddr_len = ETHARP_HWADDR_LEN; in ethernet_low_level_init() 83 netif->mtu = 1500; in ethernet_low_level_init() 87 netif->flags = NETIF_FLAG_BROADCAST | NETIF_FLAG_ETHARP | NETIF_FLAG_LINK_UP; in ethernet_low_level_init() 91 netif->flags |= NETIF_FLAG_IGMP; in ethernet_low_level_init() 107 static err_t ethernet_low_level_output(struct netif *netif, struct pbuf *p) in ethernet_low_level_output() argument 110 esp_netif_t *esp_netif = esp_netif_get_handle_from_netif_impl(netif); in ethernet_low_level_output() 113 …UGF(NETIF_DEBUG, ("corresponding esp-netif is NULL: netif=%p pbuf=%p len=%d\n", netif, p, p->len)); in ethernet_low_level_output() 158 struct netif *netif = h; in ethernetif_input() local [all …]
|
D | openthreadif.c | 28 static err_t openthread_output_ip6(struct netif *netif, struct pbuf *p, const struct ip6_addr *peer… in openthread_output_ip6() argument 31 esp_netif_t *esp_netif = esp_netif_get_handle_from_netif_impl(netif); in openthread_output_ip6() 34 …UGF(NETIF_DEBUG, ("corresponding esp-netif is NULL: netif=%p pbuf=%p len=%d\n", netif, p, p->len)); in openthread_output_ip6() 67 struct netif *netif = h; in openthread_netif_input() local 71 if (unlikely(buffer == NULL || !netif_is_up(netif))) { in openthread_netif_input() 91 if (unlikely(netif->input(p, netif) != ERR_OK)) { in openthread_netif_input() 98 err_t openthread_netif_init(struct netif *netif) in openthread_netif_init() argument 100 netif->name[0] = 'o'; in openthread_netif_init() 101 netif->name[1] = 't'; in openthread_netif_init() 102 netif->hwaddr_len = sizeof(otExtAddress); in openthread_netif_init() [all …]
|
D | dhcp_state.c | 29 #define VALID_NETIF_ID(netif) (ESP_NETIF_DHCP_CLIENT&esp_netif_get_flags(netif)) argument 31 bool dhcp_ip_addr_restore(void *netif) in dhcp_ip_addr_restore() argument 35 struct netif *net = (struct netif *)netif; in dhcp_ip_addr_restore() 37 esp_netif_t *esp_netif = esp_netif_get_handle_from_netif_impl(netif); in dhcp_ip_addr_restore() 51 void dhcp_ip_addr_store(void *netif) in dhcp_ip_addr_store() argument 54 struct netif *net = (struct netif *)netif; in dhcp_ip_addr_store() 57 esp_netif_t *esp_netif = esp_netif_get_handle_from_netif_impl(netif); in dhcp_ip_addr_store()
|
/hal_espressif-3.5.0/components/lwip/ |
D | CMakeLists.txt | 29 "lwip/src/core/netif.c" 57 "lwip/src/netif/ethernet.c" 58 "lwip/src/netif/lowpan6.c" 59 "lwip/src/netif/slipif.c" 60 "lwip/src/netif/ppp/auth.c" 61 "lwip/src/netif/ppp/ccp.c" 62 "lwip/src/netif/ppp/chap-md5.c" 63 "lwip/src/netif/ppp/chap-new.c" 64 "lwip/src/netif/ppp/chap_ms.c" 65 "lwip/src/netif/ppp/demand.c" [all …]
|
D | component.mk | 23 lwip/src/netif \ 27 port/esp32/netif \ 31 COMPONENT_OBJEXCLUDE := port/esp32/netif/ethernetif.o 39 COMPONENT_OBJEXCLUDE += port/esp32/netif/openthreadif.o 47 COMPONENT_SRCDIRS += lwip/src/netif/ppp lwip/src/netif/ppp/polarssl 56 lwip/src/netif/ppp/ppp.o: CFLAGS += -Wno-uninitialized 57 lwip/src/netif/ppp/pppos.o: CFLAGS += -Wno-implicit-fallthrough
|
/hal_espressif-3.5.0/components/esp_netif/lwip/ |
D | esp_netif_lwip_slip.c | 56 struct netif *netif_impl = esp_netif->lwip_netif; in esp_netif_new_slip() 116 esp_err_t esp_netif_slip_set_params(esp_netif_t *netif, const esp_netif_slip_config_t *slip_config) in esp_netif_slip_set_params() argument 119 lwip_slip_ctx_t *slip_ctx = (lwip_slip_ctx_t *)netif->related_data; in esp_netif_slip_set_params() 124 if (netif_is_link_up(netif->lwip_netif)) { in esp_netif_slip_set_params() 136 esp_err_t esp_netif_slip_set_ipv6(esp_netif_t *netif, const esp_ip6_addr_t *ipv6) in esp_netif_slip_set_ipv6() argument 138 lwip_slip_ctx_t *slip_ctx = (lwip_slip_ctx_t *)netif->related_data; in esp_netif_slip_set_ipv6() 143 if (netif_is_link_up(netif->lwip_netif)) { in esp_netif_slip_set_ipv6() 150 netif_ip6_addr_set(netif->lwip_netif, addr_index, (ip6_addr_t *)&slip_ctx->addr); in esp_netif_slip_set_ipv6() 151 netif_ip6_addr_set_state(netif->lwip_netif, addr_index, IP6_ADDR_VALID); in esp_netif_slip_set_ipv6() 162 esp_netif_t *netif = h; in esp_netif_lwip_slip_input() local [all …]
|
D | esp_netif_lwip_ppp.c | 53 struct netif *pppif = ppp_netif(pcb); in on_ppp_status_changed() 55 esp_netif_t *netif = ctx; in on_ppp_status_changed() local 57 .esp_netif = netif, in on_ppp_status_changed() 61 struct lwip_peer2peer_ctx *obj = (struct lwip_peer2peer_ctx*)netif->related_data; in on_ppp_status_changed() 69 esp_netif_ip_info_t *ip_info = netif->ip_info; in on_ppp_status_changed() 90 err = esp_event_post(IP_EVENT, netif->get_ip_event, &evt, sizeof(evt), 0); in on_ppp_status_changed() 139 err = esp_event_post(IP_EVENT, netif->lost_ip_event, &evt, sizeof(evt), 0); in on_ppp_status_changed() 169 err = esp_event_post(NETIF_PPP_STATUS, err_code, &netif, sizeof(netif), 0); in on_ppp_status_changed() 216 esp_netif_t *netif = ctx; in on_ppp_notify_phase() local 217 lwip_peer2peer_ctx_t *obj = (lwip_peer2peer_ctx_t *)netif->related_data; in on_ppp_notify_phase() [all …]
|
D | esp_netif_lwip_internal.h | 25 err_t (*init_fn)(struct netif*); 26 void (*input_fn)(void *netif, void *buffer, size_t len, void *eb); 30 void (*input_fn)(void *netif, void *buffer, size_t len, void *eb); 35 err_t (*init_fn)(struct netif*); 36 void (*input_fn)(void *netif, void *buffer, size_t len, void *eb); 74 #define _IS_NETIF_POINT2POINT_TYPE(netif, type) (netif->related_data && netif->related_data->is_poi… argument 76 #define _IS_NETIF_POINT2POINT_TYPE(netif, type) false argument 107 struct netif *lwip_netif; 108 err_t (*lwip_init_fn)(struct netif*);
|
D | esp_netif_lwip.c | 52 #define _RUN_IN_LWIP_TASK(function, netif, param) { return esp_netif_lwip_ipc_call(function, netif,… argument 58 #define _IS_NETIF_ANY_POINT2POINT_TYPE(netif) (netif->related_data && netif->related_data->is_point… argument 60 #define _IS_NETIF_ANY_POINT2POINT_TYPE(netif) false argument 62 #define _RUN_IN_LWIP_TASK_IF_SUPPORTED(function, netif, param) \ argument 64 if (_IS_NETIF_ANY_POINT2POINT_TYPE(netif)) { \ 67 return esp_netif_lwip_ipc_call(function, netif, (void *)(param)); \ 127 static inline esp_err_t esp_netif_lwip_ipc_call(esp_netif_api_fn fn, esp_netif_t *netif, void *data) in esp_netif_lwip_ipc_call() argument 130 .esp_netif = netif, in esp_netif_lwip_ipc_call() 136 ESP_LOGD(TAG, "check: remote, if=%p fn=%p\n", netif, fn); in esp_netif_lwip_ipc_call() 143 ESP_LOGD(TAG, "check: local, if=%p fn=%p\n", netif, fn); in esp_netif_lwip_ipc_call() [all …]
|
/hal_espressif-3.5.0/components/esp_netif/ |
D | esp_netif_objects.c | 32 esp_netif_t *netif; member 68 esp_err_t esp_netif_add_to_list(esp_netif_t *netif) in esp_netif_add_to_list() argument 72 ESP_LOGD(TAG, "%s %p", __func__, netif); in esp_netif_add_to_list() 76 item->netif = netif; in esp_netif_add_to_list() 91 esp_err_t esp_netif_remove_from_list(esp_netif_t *netif) in esp_netif_remove_from_list() argument 98 ESP_LOGV(TAG, "%s %p", __func__, netif); in esp_netif_remove_from_list() 101 if (item->netif == netif) { in esp_netif_remove_from_list() 120 esp_netif_t* esp_netif_next(esp_netif_t* netif) in esp_netif_next() argument 128 result = esp_netif_next_unsafe(netif); in esp_netif_next() 133 esp_netif_t* esp_netif_next_unsafe(esp_netif_t* netif) in esp_netif_next_unsafe() argument [all …]
|
D | README.md | 40 1) netif specific options (flags, behaviour, name) 41 2) network stack options (netif init and input functions, not publicly available) 51 …efine behaviour patterns of interaction with ESP-NETIF (example: ehternet link-up -> turn netif on) 52 * glue IO layer: adapt the input/output functions to use esp-netif transmit/input/free_rx 60 * event/action API (esp-netif lifecycle management) 64 - netif up/down 74 * `........` Initialization line from user code to esp-netif and comm driver
|
/hal_espressif-3.5.0/examples/common_components/protocol_examples_common/ |
D | connect.c | 117 static bool is_our_netif(const char *prefix, esp_netif_t *netif) in is_our_netif() argument 119 return strncmp(prefix, esp_netif_get_desc(netif), strlen(prefix) - 1) == 0; in is_our_netif() 214 esp_netif_t *netif = NULL; in example_connect() local 217 netif = esp_netif_next(netif); in example_connect() 218 if (is_our_netif(TAG, netif)) { in example_connect() 219 ESP_LOGI(TAG, "Connected to %s", esp_netif_get_desc(netif)); in example_connect() 220 ESP_ERROR_CHECK(esp_netif_get_ip_info(netif, &ip)); in example_connect() 225 int ip6_addrs = esp_netif_get_all_ip6(netif, ip6); in example_connect() 284 esp_netif_t *netif = esp_netif_create_wifi(WIFI_IF_STA, &esp_netif_config); in wifi_start() local 291 …R_CHECK(esp_event_handler_register(WIFI_EVENT, WIFI_EVENT_STA_CONNECTED, &on_wifi_connect, netif)); in wifi_start() [all …]
|
/hal_espressif-3.5.0/components/mdns/ |
D | mdns_networking_lwip.c | 73 struct netif * netif = NULL; in _udp_join_group() local 81 netif = esp_netif_get_netif_impl(tcpip_if); in _udp_join_group() 82 assert(netif); in _udp_join_group() 89 if (igmp_joingroup_netif(netif, &multicast_addr)) { in _udp_join_group() 93 if (igmp_leavegroup_netif(netif, &multicast_addr)) { in _udp_join_group() 103 if (mld6_joingroup_netif(netif, &(multicast_addr.u_addr.ip6))) { in _udp_join_group() 107 if (mld6_leavegroup_netif(netif, &(multicast_addr.u_addr.ip6))) { in _udp_join_group() 165 struct netif * netif = NULL; local 169 netif = esp_netif_get_netif_impl(_mdns_get_esp_netif(i)); 170 if (pcb && netif && netif == ip_current_input_netif ()) { [all …]
|
D | mdns_networking_socket.c | 42 static int create_socket(esp_netif_t *netif); 43 static int join_mdns_multicast_group(int sock, esp_netif_t *netif, mdns_ip_protocol_t ip_protocol); 359 esp_netif_t *netif = _mdns_get_esp_netif(tcpip_if); in create_pcb() local 362 int err = join_mdns_multicast_group(pcb_to_sock(other_pcb), netif, ip_protocol); in create_pcb() 369 int sock = create_socket(netif); in create_pcb() 374 int err = join_mdns_multicast_group(sock, netif, ip_protocol); in create_pcb() 391 static int create_socket(esp_netif_t *netif) in create_socket() argument 430 esp_netif_get_netif_impl_name(netif, ifr.ifr_name); in create_socket() 433 …"\"%s\" Unable to bind socket to specified interface: errno %d", esp_netif_get_desc(netif), errno); in create_socket() 445 static int socket_add_ipv6_multicast_group(int sock, esp_netif_t *netif) in socket_add_ipv6_multicast_group() argument [all …]
|
/hal_espressif-3.5.0/components/lwip/port/esp32/include/netif/ |
D | wlanif.h | 27 err_t wlanif_init_ap(struct netif *netif); 28 err_t wlanif_init_sta(struct netif *netif); 30 void wlanif_input(void *netif, void *buffer, size_t len, void* eb); 31 err_t wlanif_init(struct netif *netif);
|
/hal_espressif-3.5.0/examples/network/network_tests/main/ |
D | net_suite.c | 110 esp_netif_t* netif = esp_netif_new(&config); in app_main() local 111 assert(netif); in app_main() 112 esp_netif_attach(netif, netsuite_io_new()); in app_main() 116 esp_netif_set_mac(netif, mac); in app_main() 117 esp_netif_action_start(netif, NULL, 0, NULL); in app_main() 122 esp_netif_receive(netif, arp1, sizeof(arp1), NULL); in app_main() 130 esp_netif_receive(netif, packet, len, NULL); in app_main()
|
/hal_espressif-3.5.0/docs/en/api-reference/network/ |
D | esp_netif_driver.rst | 4 This section outlines implementing a new I/O driver with esp-netif connection capabilities. 5 …n the I/O driver has to register itself as an esp-netif driver and thus holds a dependency on esp-… 13 …llowing three API functions for the packet data path must be defined for connecting with esp-netif: 20 esp-netif (and its underlying TCP/IP stack) and I/O driver provides their implementation. 29 A final part of the network interface initialization consists of attaching the esp-netif instance t… 40 * related esp-netif instance 47 … esp_netif_driver_base_t base; /*!< base structure reserved as esp-netif driver */ 53 gets executed to mutually register callbacks between esp-netif and I/O driver instances. Typically … 66 driver->base.netif = esp_netif; 94 the esp-netif, specifically from its TCP/IP stack connecting layer. The following API reference out… [all …]
|
/hal_espressif-3.5.0/components/esp_wifi/src/ |
D | wifi_default.c | 316 esp_netif_t *netif = esp_netif_new(&cfg); in esp_netif_create_default_wifi_ap() local 317 assert(netif); in esp_netif_create_default_wifi_ap() 318 esp_netif_attach_wifi_ap(netif); in esp_netif_create_default_wifi_ap() 320 return netif; in esp_netif_create_default_wifi_ap() 330 esp_netif_t *netif = esp_netif_new(&cfg); in esp_netif_create_default_wifi_sta() local 331 assert(netif); in esp_netif_create_default_wifi_sta() 332 esp_netif_attach_wifi_station(netif); in esp_netif_create_default_wifi_sta() 334 return netif; in esp_netif_create_default_wifi_sta() 368 esp_netif_t *netif = esp_netif_new(&cfg); in esp_netif_create_wifi() local 369 assert(netif); in esp_netif_create_wifi() [all …]
|
/hal_espressif-3.5.0/components/lwip/test_afl_host/ |
D | network_mock.c | 14 struct netif *netif_list; 159 err_t etharp_query(struct netif *netif, const ip4_addr_t *ipaddr, struct pbuf *q) in etharp_query() argument 164 void netif_set_addr(struct netif *netif, const ip4_addr_t *ipaddr, const ip4_addr_t *netmask, in netif_set_addr() argument 223 …(struct udp_pcb *pcb, struct pbuf *p, const ip_addr_t *dst_ip, u16_t dst_port, struct netif *netif) in udp_sendto_if() argument 228 …*pcb, struct pbuf *p, const ip_addr_t *dst_ip, u16_t dst_port, struct netif *netif, const ip_addr_… in udp_sendto_if_src() argument
|
/hal_espressif-3.5.0/components/tcpip_adapter/ |
D | tcpip_adapter_compat.c | 224 esp_err_t tcpip_adapter_get_netif(tcpip_adapter_if_t tcpip_if, void ** netif) in tcpip_adapter_get_netif() argument 229 *netif = net_stack_netif; in tcpip_adapter_get_netif() 300 static esp_err_t tcpip_adapter_compat_start_netif(esp_netif_t *netif, uint8_t *mac, tcpip_adapter_i… in tcpip_adapter_compat_start_netif() argument 302 if (netif == NULL || mac == NULL || ip_info == NULL) { in tcpip_adapter_compat_start_netif() 305 esp_netif_set_mac(netif, mac); in tcpip_adapter_compat_start_netif() 306 esp_netif_set_ip_info(netif, (esp_netif_ip_info_t *)ip_info); in tcpip_adapter_compat_start_netif() 307 esp_netif_action_start(netif, NULL, 0, NULL); in tcpip_adapter_compat_start_netif() 333 esp_netif_t *netif = netif_from_if(tcpip_if); in tcpip_adapter_stop() local 334 if (netif == NULL) { in tcpip_adapter_stop() 363 esp_netif_t *netif = esp_netif_get_handle_from_netif_impl(dev); in tcpip_adapter_get_esp_if() local [all …]
|
/hal_espressif-3.5.0/components/mdns/host_test/components/esp_netif_linux/ |
D | esp_netif_linux.c | 138 esp_netif_t* netif = calloc(1, sizeof(struct esp_netif_obj)); in esp_netif_new() local 139 if (netif) { in esp_netif_new() 140 netif->if_desc = config->base->if_desc; in esp_netif_new() 141 netif->if_key = config->base->if_key; in esp_netif_new() 146 s_netif_list[i] = netif; in esp_netif_new() 151 return netif; in esp_netif_new()
|
/hal_espressif-3.5.0/components/mdns/test_afl_fuzz_host/ |
D | esp_netif_mock.c | 30 esp_err_t esp_netif_add_to_list(esp_netif_t *netif) in esp_netif_add_to_list() argument 35 esp_err_t esp_netif_remove_from_list(esp_netif_t *netif) in esp_netif_remove_from_list() argument 40 esp_netif_t* esp_netif_next(esp_netif_t* netif) in esp_netif_next() argument 45 esp_netif_t* esp_netif_next_unsafe(esp_netif_t* netif) in esp_netif_next_unsafe() argument
|
/hal_espressif-3.5.0/components/lwip/port/esp32/hooks/ |
D | lwip_default_hooks.c | 20 struct netif *__weak 43 const ip6_addr_t *__weak lwip_hook_nd6_get_gw(struct netif *netif, const ip6_addr_t *dest) in lwip_hook_nd6_get_gw() argument 45 LWIP_UNUSED_ARG(netif); in lwip_hook_nd6_get_gw()
|
/hal_espressif-3.5.0/examples/protocols/static_ip/main/ |
D | static_ip_example_main.c | 54 static esp_err_t example_set_dns_server(esp_netif_t *netif, uint32_t addr, esp_netif_dns_type_t typ… in example_set_dns_server() argument 60 ESP_ERROR_CHECK(esp_netif_set_dns_info(netif, type, &dns)); in example_set_dns_server() 65 static void example_set_static_ip(esp_netif_t *netif) in example_set_static_ip() argument 67 if (esp_netif_dhcpc_stop(netif) != ESP_OK) { in example_set_static_ip() 76 if (esp_netif_set_ip_info(netif, &ip) != ESP_OK) { in example_set_static_ip() 81 …ESP_ERROR_CHECK(example_set_dns_server(netif, ipaddr_addr(EXAMPLE_MAIN_DNS_SERVER), ESP_NETIF_DNS_… in example_set_static_ip() 82 …ESP_ERROR_CHECK(example_set_dns_server(netif, ipaddr_addr(EXAMPLE_BACKUP_DNS_SERVER), ESP_NETIF_DN… in example_set_static_ip()
|