Zephyr 4.2.0 problem with esp_restart()
Posted: Fri Oct 24, 2025 2:44 pm
Hi All,
My project is a device based on the Seeed Xiao ESP32C3 running Zephyr RTOS.
I have upgraded my project from Zephyr 4.1.0 to 4.2.0 and it won't build.
The code calls esp_restart() when certain errors occur that indicate memory is running out. Previously I included #include <esp_system.h> in the code module and it worked fine.
After upgrading to Zephyr 4.2.0, I am getting "multiple definition" errors for 'esp_restart' and 'esp_unregister_shutdown_handler' and my build fails at that point. I note that the function esp_restart() is present in both esp_system.c and esp_restart.c.
Any clues about how to fix this would be much appreciated.
Thanks in advance,
Rob
My project is a device based on the Seeed Xiao ESP32C3 running Zephyr RTOS.
I have upgraded my project from Zephyr 4.1.0 to 4.2.0 and it won't build.
The code calls esp_restart() when certain errors occur that indicate memory is running out. Previously I included #include <esp_system.h> in the code module and it worked fine.
After upgrading to Zephyr 4.2.0, I am getting "multiple definition" errors for 'esp_restart' and 'esp_unregister_shutdown_handler' and my build fails at that point. I note that the function esp_restart() is present in both esp_system.c and esp_restart.c.
Any clues about how to fix this would be much appreciated.
Thanks in advance,
Rob