Commit Graph

153 Commits

Author SHA1 Message Date
Zhang Wen Xu
3c9cd354ec Merge branch 'bugfix/esp_netif_get_ip6addr_should_be_valid' into 'master'
fix(esp_netif): netif should return only valid addr

See merge request espressif/esp-idf!31880
2024-07-09 11:17:44 +08:00
David Čermák
6a75241bf1 Merge branch 'feat/esp_netif_dns_switch' into 'master'
fix(esp_netif): Restore DNS servers when choosing the default netif

Closes IDFGH-4440

See merge request espressif/esp-idf!30996
2024-07-08 16:41:16 +08:00
David Cermak
6acdb384f6 fix(esp_netif): Restore DNS servers per netif when setting it default
Introducing config option `CONFIG_ESP_NETIF_SET_DNS_PER_DEFAULT_NETIF`
to overcome LWIP limitation of using global DNS server info.
This config option enables LWIP callbacks to collect per netif DNS
server info and then restores global DNS servers of whichever network
interface is selected as default.

LWIP submodule update: git log --oneline aa4f6e78..3a3d1fb3
- dns: Allow storing dnsserver per netif (espressif/esp-lwip@3a3d1fb3)
2024-07-04 10:37:22 +02:00
David Čermák
ce4313a569 Merge branch 'fix/netif_ppp_ip6_autoconfig' into 'master'
fix(esp_netif): Fix missing IPv6 autoconfig for PPP netifs

Closes IDFGH-12730

See merge request espressif/esp-idf!31330
2024-07-04 14:14:52 +08:00
zwx
64aa5db0cd fix(esp_netif): netif should return only valid addr 2024-07-03 15:07:18 +08:00
Alexey Lapshin
b0ba5689f1 Merge branch 'feature/gcc-fanalyzer' into 'master'
feat(ci): add gnu static analyzer job

See merge request espressif/esp-idf!30902
2024-06-19 19:31:53 +08:00
David Čermák
1fd6a83f62 Merge branch 'fix/netif_napt_fix' into 'master'
fix(esp_netif): Don't warn about disabling napt if wasn't enabled

See merge request espressif/esp-idf!31076
2024-06-19 17:36:22 +08:00
Alexey Lapshin
ed6e497c6f feat(build): add COMPILER_STATIC_ANALYZER option 2024-06-18 14:25:37 +08:00
Yogesh Mantri
586207207f change(esp_netif): Add Non-Fatal errtype to indicate lower layer medium failure
UDP application sends packet using esp_netif, underlying transport such
as Wi-Fi may drop the packet due to higher load. New error code
represent transient, non-fatal packet drop error. udp application may
use such errtype, for example to rate limit.
2024-06-11 09:20:49 +02:00
David Cermak
d3567b080f fix(esp_netif): Don't warn about disabling napt if wasn't enabled 2024-06-10 13:34:06 +02:00
David Cermak
3a63cb80bb fix(esp_netif): Fix missing IPv6 autoconfig for PPP netifs
Closes https://github.com/espressif/esp-idf/issues/13713
2024-06-05 08:28:18 +02:00
David Cermak
99b0a765a8 fix(esp_netif): Fix PPP server to negotiate its own address is configured
Closes https://github.com/espressif/esp-protocols/issues/565
2024-05-29 18:03:04 +08:00
Wang Qixiang
a2be60a697 Merge branch 'bugfix/mldv6_report_memory_leak' into 'master'
fix(esp_netif): Fix mldv6 report memory leak in esp_netif

Closes IDF-9990

See merge request espressif/esp-idf!30916
2024-05-24 15:06:13 +08:00
Abhik Roy
443843b362 Merge branch 'examples/icmpv6_ping_readme_update' into 'master'
docs(examples): Added network config to icmpv6_ping readme

Closes IDFGH-11853 and IDF-9847

See merge request espressif/esp-idf!29400
2024-05-21 18:23:45 +08:00
WanqQixiang
1595388a7e fix(esp_netif): Fix mldv6 report memory leak in esp_netif 2024-05-17 15:53:55 +08:00
Abhik Roy
437f08100d fix(esp_netif): Fixed Coverity issue CID 459204
Closes IDF-9847

See merge request espressif/esp-idf!29400
2024-05-07 20:43:22 +10:00
jkingsman
3035ce294d feat(esp_netif): add support for DHCP Option 114 captive portal URI
DHCP Option 114 provides a modern method of indicating a captive
portal redirect to DHCP client. This introduces Option 114 to
the DHCPS component as well as provides examples for usage.
2024-05-02 22:50:09 +08:00
Abhik Roy
ad9787bb4d feat(esp_netif): Allow traffic reporting runtime enable/disable 2024-04-22 11:27:43 +10:00
Dr. Michael Lauer
5debb23da9 feat(esp_netif): Allow traffic reporting
This enables traffic indicators or data traffic statistics.
2024-04-22 11:22:29 +10:00
David Cermak
965ba606a7 fix(esp_netif): Post IP_CHANGE event also if mask and GW is ANY
Closes https://github.com/espressif/esp-idf/issues/12927
2024-04-04 08:12:43 +02:00
David Cermak
c30f2825d5 fix(netif): Add missing SNTP get-reachablitiy API 2024-02-29 23:37:45 +08:00
David Cermak
feef14b43b fix(esp_netif): Prevent running esp_netif_sntp_init() multiple times
Closes https://github.com/espressif/esp-idf/issues/12854
2024-02-07 09:09:59 +01:00
David Cermak
73102c60ef fix(lwip): Used dedicated IP4 address type 2024-01-19 17:48:47 +01:00
David Cermak
d707161881 fix(lwip): esp_netif supports esp_netif_get_netif_impl() for PPP 2024-01-18 14:20:39 +08:00
David Cermak
18ff62017a feat(lwip): Add support for PPP server
Added support PPP_SERVER option in LWIP
Added support for configuring preferred addresses of PPP endpoints.
2024-01-18 14:20:39 +08:00
Abhik Roy
325a8d7a6e feat(esp_netif): Added code to expose api to add and remove ipv6 address 2024-01-09 18:00:47 +08:00
xueyunfei
02c1a1c6af fix(dhcp server):dhcp server can not restore address pool 2023-12-05 15:56:20 +08:00
xueyunfei
5982d1cda4 Fix(dhcps):fix dhcp subnet option api dos not work issue 2023-11-15 10:53:50 +08:00
Xue Yun Fei
e64712b263 Merge branch 'lost_timer_failed_to_start_when_sta_is_connected' into 'master'
esp-netif:lost timer failed to start when sta is disconnected

Closes WIFI-5984

See merge request espressif/esp-idf!24076
2023-10-19 14:12:17 +08:00
David Čermák
210f757835 Merge branch 'fix/esp_netif_lock' into 'master'
fix(esp_netif): Lock netif list with TCPIP context

Closes IDFGH-11088

See merge request espressif/esp-idf!26164
2023-10-17 21:36:39 +08:00
David Cermak
88d18e9a40 fix(esp_netif): Mark esp_netif_next deprecated and fix usages
* Uses netif_find_if() in IPv6 examples
* Fixes esp_netif_next() usage in L2TAP
2023-10-13 15:56:45 +02:00
David Cermak
606363897c feat(esp_netif): Added new API to search in netif list 2023-10-13 15:56:30 +02:00
David Cermak
36735f4d77 fix(esp_netif): Lock netif list with TCPIP context
This commit removes the lock from the list manipulation code in esp_netif_objects.c,
 because we already have another lock/task context for lwip.
So the list manipulation is unsafe and safety must be assured by the stack layer
(in esp_netif_lwip).
Problems with current locking:
* implementation of locking was wrong -- lazy init style of creating the mutex is not
  thread safe (and destroying it if we have no interface makes the problem exhibit very frequently)
* locking only the list won't solve issues when assessing interfaces atomically
* maintaining multiple locks is problematic, as we often switch between
lwip context and user context in internal implementation of esp_netif_lwip

Closes https://github.com/espressif/esp-idf/issues/12261
2023-10-13 15:54:53 +02:00
xueyunfei
e9949d4782 lost timer failed to start when sta is connected 2023-10-09 02:14:25 +00:00
David Cermak
10a5fcf99e feat(esp_netif): PPP: Use RAM allocated pbufs instead of POOL (fixed size)
PPP netif: Used allocated packet buffers of exact size
for input to TCP/IP stack to consume less memory in download mode
(compared to the previously used fixed sized packet buffers)
2023-09-25 16:48:48 +02:00
David Cermak
966b8620c2 feat(esp_netif): PPP config option to allow disabling LCP runtime
If LCP keepalive mechanism is enabled in menuconfig, it's statically
configured on creation of an interface and cannot be changed runtime. In
some cases it's useful to relax LCP criteria during runtime operation,
for example before initiating OTA. This config option allows for
disabling already enabled LCP echo (this setting becomes effective after
reconnecting, i.e. initializing a new session)

Closes https://github.com/espressif/esp-protocols/issues/287
2023-09-25 16:48:48 +02:00
xueyunfei
fff7c6a399 fix(dhcp server):fix set dhcp server poll fail issue 2023-09-13 10:20:02 +08:00
David Cermak
ca44460359 esp_netif: Fix Wno-format issues 2023-08-14 14:13:33 +02:00
Ondrej Kosta
3288f83401 feat(network/examples): extended LwIP bridge example
Extended LwIP bridge example to support WiFi AP interface and DHCP Server

https://github.com/espressif/esp-idf/issues/5697
2023-06-30 14:38:24 +02:00
KonstantinKondrashov
e72061695e all: Removes unnecessary newline character in logs
Closes https://github.com/espressif/esp-idf/issues/11465
2023-06-09 03:31:21 +08:00
David Cermak
7d6241e761 esp_netif: Make esp_netif_receive() return value configurable 2023-04-05 12:18:21 +02:00
David Cermak
8855ddf044 esp_netif: Report error if esp_netif_receive() fails
Closes https://github.com/espressif/esp-idf/issues/10770
2023-04-05 12:18:21 +02:00
Abhik Roy
8e71e96603 lwip/esp_napt: Added api to enable/disable napt based on esp_netif. 2023-03-23 20:38:03 +11:00
David Cermak
97e785c01d lwip:esp_netif: Send Periodic Gratuitous ARP only on valid IPv4
It was possible that the device would send a Gratuitous ARP before
acquiring a valid address, advertising it has 0.0.0.0 address.
2023-03-17 09:18:53 +01:00
Nachiket Kukade
4c76af3f68 esp_wifi: Add support for NAN Discovery and Datapath
Update wifi lib with below -
1. Create NAN Discovery SM for beaconing & cluster formation
2. Create NAN interface for Tx/Rx of beacons & action frames
3. Add commands & events for NAN Services Publish/Subscribe/Followup
4. Add NAN Datapath definitions, Events, Peer structures
5. Support for forming and parsing of Datapath related attributes
6. Modules for NDP Req, Resp, Confirm, Term, Peer management
7. NAN Interface related additions in Datapath, Data Tx Q's

In addition include below changes -
1. Add netif and driver support for NAN Interface
2. Add simple examples for Publisher-Subscriber usecases
3. Add an advanced console example that supports commands
   for NAN Discovery, Services & Datapath
4. Add wifi_apps for providing better NAN API's and Peer management

Co-authored-by: Shyamal Khachane <shyamal.khachane@espressif.com>
2023-03-10 11:18:23 +05:30
xueyunfei
ad0b32c662 lwip: solve some routers do not forward multicast packet issue 2023-03-08 16:58:29 +08:00
David Cermak
5f6cb31105 lwip: Support IPv6 only mode 2023-02-27 08:53:34 +01:00
David Cermak
fa97004faf lwip: Support for linux target
Implement linux port layer and reuse the original FreeRTOS layer
that's compiled and used on linux target as well, by means of FreeRTOS
simulator.
2023-01-31 08:43:45 +01:00
Abhik Roy
9cf70e0c98 Merge branch 'lwip/restrict_dhcp_server_client_together' into 'master'
esp-lwip: Restrict configuring DHCP server and client together

See merge request espressif/esp-idf!22137
2023-01-27 22:36:30 +08:00
Abhik Roy
d762f9a1a5 esp-lwip: Added check in esp_netif_new() to restrict configuring DHCP
server and client together.
2023-01-26 20:59:04 +05:30