Migration guide to Zephyr v4.6.0 (Working Draft)
This document describes the changes required when migrating your application from Zephyr v4.5.0 to Zephyr v4.6.0.
Any other changes (not directly related to migrating applications) can be found in the release notes.
Common
Build System
Kernel
Boards
Device Drivers and Devicetree
ADC
nxp,lpc-lpadcchannels that useADC_GAIN_1_2for the 30/64 partial scale should useADC_GAIN_15_32: withADC_GAIN_1_2, which still selects that scale, the conversions ofadc_raw_to_millivolts_dt()andadc_raw_to_millivolts()are 6.25% too low.
Ethernet
CONFIG_ETH_PHY_DRIVERis no longer enabled by default. It is now selected by the Ethernet drivers that need a PHY driver. Out-of-tree Ethernet drivers that use a PHY driver must select it as well. (GitHub #120871)
OPAMP
The NXP OPAMP drivers (
nxp,opampandnxp,opamp-fast) hold a power state constraint while the device is active, and the OPAMP nodes declarezephyr,disabling-power-states. WithCONFIG_PM_POLICY_DEVICE_CONSTRAINTSan enabled OPAMP therefore keeps the system out of Power Down and Deep Power Down for as long as it is active, which withoutCONFIG_PM_DEVICE_RUNTIMEis from init onwards. Enable device runtime PM for the node, or suspend it explicitly, to let the system reach those states. (GitHub #122135)nxp,opamp-fastno longer enables an instance marked withis-reference-sourcefrom its init function; the instance follows its own power state like every other instance. WithCONFIG_PM_DEVICE_RUNTIMEan application has to hold a runtime reference on the reference source while it measures an amplifier fed by it. Builds without device runtime PM are unaffected: the device is resumed at init and the instance comes up enabled as before. (GitHub #122135)
Bluetooth
Bluetooth Classic
The L2CAP BR/EDR ECHO API is now only available with
CONFIG_BT_TESTING:bt_l2cap_br_echo_cb,bt_l2cap_br_echo_cb_register(),bt_l2cap_br_echo_cb_unregister(),bt_l2cap_br_echo_req()andbt_l2cap_br_echo_rsp(). The stack answers a received ECHO request with an ECHO response without data, unless a registeredreqcallback handles it.