drivers: serial: nrfx_uarte: Deprecate non-legacy shim
Some time ago a new shim for nRF UARTE was added (uart_nrfx_uarte2.c) which used nrfx_uarte.c driver underneath. It was supposed to support nrf54x platforms. However, later on legacy driver (uart_nrfx_uarte.c) was extended to support nrf54x platforms and it takes less code size, has better performance and more features. Shim uart_nrfx_uarte2 will no longer be supported. As new shim is the default and there is a Kconfig to pick the legacy shim (CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=y) it cannot be deprecated in the normal way. Additional Kconfig option is created (DEPRECATED_UART_NRFX_UARTE_LEGACY_SHIM) which is enabled if CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=n and it selects DEPRECATED. A warning was also added to the CMakeLists.txt. Patch removes use CONFIG_UART_NRFX_UARTE_LEGACY_SHIM in tests. Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
This commit is contained in:
parent
bd9249457a
commit
70118c06a5
6 changed files with 11 additions and 22 deletions
|
|
@ -93,6 +93,8 @@ if (CONFIG_UART_NRFX_UARTE)
|
||||||
if (CONFIG_UART_NRFX_UARTE_LEGACY_SHIM)
|
if (CONFIG_UART_NRFX_UARTE_LEGACY_SHIM)
|
||||||
zephyr_library_sources(uart_nrfx_uarte.c)
|
zephyr_library_sources(uart_nrfx_uarte.c)
|
||||||
else()
|
else()
|
||||||
|
message(DEPRECATION
|
||||||
|
"Do not set CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=n as this option is deprecated.")
|
||||||
zephyr_library_sources(uart_nrfx_uarte2.c)
|
zephyr_library_sources(uart_nrfx_uarte2.c)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
|
||||||
|
|
@ -32,6 +32,8 @@ config UART_NRFX_UARTE_LEGACY_SHIM
|
||||||
bool "Legacy UARTE shim"
|
bool "Legacy UARTE shim"
|
||||||
depends on UART_NRFX_UARTE
|
depends on UART_NRFX_UARTE
|
||||||
default y
|
default y
|
||||||
|
help
|
||||||
|
Disabling this option is deprecated.
|
||||||
|
|
||||||
config UART_NRFX_UARTE_ENHANCED_RX
|
config UART_NRFX_UARTE_ENHANCED_RX
|
||||||
bool "Enhanced RX handling"
|
bool "Enhanced RX handling"
|
||||||
|
|
|
||||||
|
|
@ -197,4 +197,9 @@ config NRF_PLATFORM_HALTIUM
|
||||||
this option. This allows to easily enable common functionality on
|
this option. This allows to easily enable common functionality on
|
||||||
SoCs based on the Haltium platform.
|
SoCs based on the Haltium platform.
|
||||||
|
|
||||||
|
config DEPRECATED_UART_NRFX_UARTE_LEGACY_SHIM
|
||||||
|
bool
|
||||||
|
default y if !UART_NRFX_UARTE_LEGACY_SHIM
|
||||||
|
select DEPRECATED
|
||||||
|
|
||||||
endif # SOC_FAMILY_NORDIC_NRF
|
endif # SOC_FAMILY_NORDIC_NRF
|
||||||
|
|
|
||||||
|
|
@ -25,20 +25,6 @@ tests:
|
||||||
platform_allow: nucleo_h743zi
|
platform_allow: nucleo_h743zi
|
||||||
integration_platforms:
|
integration_platforms:
|
||||||
- nucleo_h743zi
|
- nucleo_h743zi
|
||||||
drivers.uart.async_api.nrf_uarte_new:
|
|
||||||
platform_allow:
|
|
||||||
- nrf52840dk/nrf52840
|
|
||||||
- nrf52_bsim
|
|
||||||
- nrf5340bsim/nrf5340/cpuapp
|
|
||||||
- nrf54l20pdk/nrf54l20/cpuapp
|
|
||||||
- nrf54l15bsim/nrf54l15/cpuapp
|
|
||||||
filter: CONFIG_SERIAL_SUPPORT_ASYNC
|
|
||||||
harness: ztest
|
|
||||||
harness_config:
|
|
||||||
fixture: gpio_loopback
|
|
||||||
depends_on: gpio
|
|
||||||
extra_configs:
|
|
||||||
- CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=n
|
|
||||||
drivers.uart.async_api.nrf_uart:
|
drivers.uart.async_api.nrf_uart:
|
||||||
filter: CONFIG_SERIAL_SUPPORT_ASYNC
|
filter: CONFIG_SERIAL_SUPPORT_ASYNC
|
||||||
harness: ztest
|
harness: ztest
|
||||||
|
|
|
||||||
|
|
@ -1 +0,0 @@
|
||||||
CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=n
|
|
||||||
|
|
@ -23,14 +23,12 @@ tests:
|
||||||
- CONFIG_UART_INTERRUPT_DRIVEN=n
|
- CONFIG_UART_INTERRUPT_DRIVEN=n
|
||||||
- CONFIG_UART_ASYNC_API=n
|
- CONFIG_UART_ASYNC_API=n
|
||||||
- CONFIG_UART_0_ENHANCED_POLL_OUT=n
|
- CONFIG_UART_0_ENHANCED_POLL_OUT=n
|
||||||
- CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=y
|
|
||||||
|
|
||||||
drivers.uart.pm.no_rxpin:
|
drivers.uart.pm.no_rxpin:
|
||||||
extra_configs:
|
extra_configs:
|
||||||
- CONFIG_UART_INTERRUPT_DRIVEN=n
|
- CONFIG_UART_INTERRUPT_DRIVEN=n
|
||||||
- CONFIG_UART_ASYNC_API=n
|
- CONFIG_UART_ASYNC_API=n
|
||||||
- CONFIG_UART_0_ENHANCED_POLL_OUT=n
|
- CONFIG_UART_0_ENHANCED_POLL_OUT=n
|
||||||
- CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=y
|
|
||||||
extra_args: DTC_OVERLAY_FILE="boards/nrf52840dk_nrf52840.overlay;nrf_rx_disable.overlay"
|
extra_args: DTC_OVERLAY_FILE="boards/nrf52840dk_nrf52840.overlay;nrf_rx_disable.overlay"
|
||||||
platform_exclude:
|
platform_exclude:
|
||||||
- nrf54l09pdk/nrf54l09/cpuapp
|
- nrf54l09pdk/nrf54l09/cpuapp
|
||||||
|
|
@ -38,13 +36,14 @@ tests:
|
||||||
- nrf54l20pdk/nrf54l20/cpuapp
|
- nrf54l20pdk/nrf54l20/cpuapp
|
||||||
- nrf54l15bsim/nrf54l15/cpuapp
|
- nrf54l15bsim/nrf54l15/cpuapp
|
||||||
- nrf54h20dk/nrf54h20/cpuapp
|
- nrf54h20dk/nrf54h20/cpuapp
|
||||||
|
- nrf52_bsim
|
||||||
|
- nrf5340bsim/nrf5340/cpuapp
|
||||||
|
|
||||||
drivers.uart.pm.enhanced_poll:
|
drivers.uart.pm.enhanced_poll:
|
||||||
extra_configs:
|
extra_configs:
|
||||||
- CONFIG_UART_INTERRUPT_DRIVEN=n
|
- CONFIG_UART_INTERRUPT_DRIVEN=n
|
||||||
- CONFIG_UART_ASYNC_API=n
|
- CONFIG_UART_ASYNC_API=n
|
||||||
- CONFIG_UART_0_ENHANCED_POLL_OUT=y
|
- CONFIG_UART_0_ENHANCED_POLL_OUT=y
|
||||||
- CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=y
|
|
||||||
platform_exclude:
|
platform_exclude:
|
||||||
- nrf54l09pdk/nrf54l09/cpuapp
|
- nrf54l09pdk/nrf54l09/cpuapp
|
||||||
- nrf54l15dk/nrf54l15/cpuapp
|
- nrf54l15dk/nrf54l15/cpuapp
|
||||||
|
|
@ -57,7 +56,6 @@ tests:
|
||||||
- CONFIG_UART_0_INTERRUPT_DRIVEN=y
|
- CONFIG_UART_0_INTERRUPT_DRIVEN=y
|
||||||
- CONFIG_UART_ASYNC_API=n
|
- CONFIG_UART_ASYNC_API=n
|
||||||
- CONFIG_UART_0_ENHANCED_POLL_OUT=n
|
- CONFIG_UART_0_ENHANCED_POLL_OUT=n
|
||||||
- CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=y
|
|
||||||
|
|
||||||
drivers.uart.pm.int_driven.enhanced_poll:
|
drivers.uart.pm.int_driven.enhanced_poll:
|
||||||
extra_configs:
|
extra_configs:
|
||||||
|
|
@ -65,7 +63,6 @@ tests:
|
||||||
- CONFIG_UART_0_INTERRUPT_DRIVEN=y
|
- CONFIG_UART_0_INTERRUPT_DRIVEN=y
|
||||||
- CONFIG_UART_ASYNC_API=n
|
- CONFIG_UART_ASYNC_API=n
|
||||||
- CONFIG_UART_0_ENHANCED_POLL_OUT=y
|
- CONFIG_UART_0_ENHANCED_POLL_OUT=y
|
||||||
- CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=y
|
|
||||||
platform_exclude:
|
platform_exclude:
|
||||||
- nrf54l09pdk/nrf54l09/cpuapp
|
- nrf54l09pdk/nrf54l09/cpuapp
|
||||||
- nrf54l15dk/nrf54l15/cpuapp
|
- nrf54l15dk/nrf54l15/cpuapp
|
||||||
|
|
@ -78,7 +75,6 @@ tests:
|
||||||
- CONFIG_UART_ASYNC_API=y
|
- CONFIG_UART_ASYNC_API=y
|
||||||
- CONFIG_UART_0_ASYNC=y
|
- CONFIG_UART_0_ASYNC=y
|
||||||
- CONFIG_UART_0_ENHANCED_POLL_OUT=n
|
- CONFIG_UART_0_ENHANCED_POLL_OUT=n
|
||||||
- CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=y
|
|
||||||
|
|
||||||
drivers.uart.pm.async.enhanced_poll:
|
drivers.uart.pm.async.enhanced_poll:
|
||||||
extra_configs:
|
extra_configs:
|
||||||
|
|
@ -86,7 +82,6 @@ tests:
|
||||||
- CONFIG_UART_ASYNC_API=y
|
- CONFIG_UART_ASYNC_API=y
|
||||||
- CONFIG_UART_0_ASYNC=y
|
- CONFIG_UART_0_ASYNC=y
|
||||||
- CONFIG_UART_0_ENHANCED_POLL_OUT=y
|
- CONFIG_UART_0_ENHANCED_POLL_OUT=y
|
||||||
- CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=y
|
|
||||||
platform_exclude:
|
platform_exclude:
|
||||||
- nrf54l09pdk/nrf54l09/cpuapp
|
- nrf54l09pdk/nrf54l09/cpuapp
|
||||||
- nrf54l15dk/nrf54l15/cpuapp
|
- nrf54l15dk/nrf54l15/cpuapp
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue