From 7a6cf0f9c0e568e7014600bc98eccd11120614dc Mon Sep 17 00:00:00 2001 From: David Cermak Date: Wed, 8 Oct 2025 16:20:18 +0200 Subject: [PATCH 1/3] fix(eppp): Fix tun netif to (optionally) return errors --- components/eppp_link/eppp_netif_tun.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/components/eppp_link/eppp_netif_tun.c b/components/eppp_link/eppp_netif_tun.c index 7b905213e..01f9ed2bb 100644 --- a/components/eppp_link/eppp_netif_tun.c +++ b/components/eppp_link/eppp_netif_tun.c @@ -17,9 +17,17 @@ #include "esp_check.h" #include "esp_idf_version.h" +#if defined(CONFIG_ESP_NETIF_RECEIVE_REPORT_ERRORS) +typedef esp_err_t esp_netif_recv_ret_t; +#define ESP_NETIF_OPTIONAL_RETURN_CODE(expr) expr +#else +typedef void esp_netif_recv_ret_t; +#define ESP_NETIF_OPTIONAL_RETURN_CODE(expr) +#endif // CONFIG_ESP_NETIF_RECEIVE_REPORT_ERRORS + static const char *TAG = "eppp_tun_netif"; -static void tun_input(void *h, void *buffer, unsigned int len, void *eb) +static esp_netif_recv_ret_t tun_input(void *h, void *buffer, unsigned int len, void *eb) { __attribute__((unused)) esp_err_t ret = ESP_OK; struct netif *netif = h; @@ -31,11 +39,12 @@ static void tun_input(void *h, void *buffer, unsigned int len, void *eb) ESP_GOTO_ON_FALSE(pbuf_remove_header(p, SIZEOF_ETH_HDR) == 0, ESP_FAIL, err, TAG, "pbuf_remove_header failed"); memcpy(p->payload, buffer, len); ESP_GOTO_ON_FALSE(netif->input(p, netif) == ERR_OK, ESP_FAIL, err, TAG, "failed to input packet to lwip"); - return; + return ESP_NETIF_OPTIONAL_RETURN_CODE(ESP_OK); err: if (p) { pbuf_free(p); } + return ESP_NETIF_OPTIONAL_RETURN_CODE(ret); } static err_t tun_output(struct netif *netif, struct pbuf *p) From 1ace92c2790853411371e91706fd4a1969f55ebf Mon Sep 17 00:00:00 2001 From: David Cermak Date: Wed, 8 Oct 2025 16:43:14 +0200 Subject: [PATCH 2/3] fix(eppp): Fix test dependency issue on driver --- components/eppp_link/test/test_app/main/CMakeLists.txt | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/components/eppp_link/test/test_app/main/CMakeLists.txt b/components/eppp_link/test/test_app/main/CMakeLists.txt index c75a706cc..708acff79 100644 --- a/components/eppp_link/test/test_app/main/CMakeLists.txt +++ b/components/eppp_link/test/test_app/main/CMakeLists.txt @@ -1,4 +1,10 @@ +if("${IDF_VERSION_MAJOR}.${IDF_VERSION_MINOR}" VERSION_GREATER "5.3") + set(driver_deps esp_driver_gpio esp_driver_spi esp_driver_uart esp_driver_sdio) +else() + set(driver_deps driver) +endif() + idf_component_register(SRCS app_main.c INCLUDE_DIRS "." REQUIRES test_utils - PRIV_REQUIRES unity nvs_flash esp_netif driver esp_event) + PRIV_REQUIRES unity nvs_flash esp_netif esp_event ${driver_deps}) From 44524f5de07ce0f8a47151eaad052c01ba1f4c1d Mon Sep 17 00:00:00 2001 From: David Cermak Date: Thu, 9 Oct 2025 13:04:46 +0200 Subject: [PATCH 3/3] bump(eppp): 1.1.2 -> 1.1.3 1.1.3 Bug Fixes - Fix test dependency issue on driver (1ace92c2) - Fix tun netif to (optionally) return errors (7a6cf0f9) --- components/eppp_link/.cz.yaml | 2 +- components/eppp_link/CHANGELOG.md | 7 +++++++ components/eppp_link/idf_component.yml | 2 +- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/components/eppp_link/.cz.yaml b/components/eppp_link/.cz.yaml index bd413845d..73f5b9317 100644 --- a/components/eppp_link/.cz.yaml +++ b/components/eppp_link/.cz.yaml @@ -3,6 +3,6 @@ commitizen: bump_message: 'bump(eppp): $current_version -> $new_version' pre_bump_hooks: python ../../ci/changelog.py eppp_link tag_format: eppp-v$version - version: 1.1.2 + version: 1.1.3 version_files: - idf_component.yml diff --git a/components/eppp_link/CHANGELOG.md b/components/eppp_link/CHANGELOG.md index 4aeaf7775..81e923aa3 100644 --- a/components/eppp_link/CHANGELOG.md +++ b/components/eppp_link/CHANGELOG.md @@ -1,5 +1,12 @@ # Changelog +## [1.1.3](https://github.com/espressif/esp-protocols/commits/eppp-v1.1.3) + +### Bug Fixes + +- Fix test dependency issue on driver ([1ace92c2](https://github.com/espressif/esp-protocols/commit/1ace92c2)) +- Fix tun netif to (optionally) return errors ([7a6cf0f9](https://github.com/espressif/esp-protocols/commit/7a6cf0f9)) + ## [1.1.2](https://github.com/espressif/esp-protocols/commits/eppp-v1.1.2) ### Bug Fixes diff --git a/components/eppp_link/idf_component.yml b/components/eppp_link/idf_component.yml index 06d8b9def..0ff8b9096 100644 --- a/components/eppp_link/idf_component.yml +++ b/components/eppp_link/idf_component.yml @@ -1,4 +1,4 @@ -version: 1.1.2 +version: 1.1.3 url: https://github.com/espressif/esp-protocols/tree/master/components/eppp_link description: The component provides a general purpose PPP connectivity, typically used as WiFi-PPP router dependencies: