Commit ba86c101 authored by James Smith's avatar James Smith Committed by Johan Hedberg
Browse files

modules: hal_silabs: Set multiprotocol define based on Kconfig



Set `SL_RAIL_LIB_MULTIPROTOCOL_SUPPORT` to `1` when Rail
Multiprotocol Kconfig is enabled.

This is required to run the Bluetooth multiprotocol initialization
code during `sl_btctrl_init`.

Signed-off-by: default avatarJames Smith <james@loopj.com>
parent 92be5346
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -50,8 +50,11 @@ if(${CONFIG_SOC_GECKO_HAS_RADIO})

    # prebuilt libs
    if(CONFIG_SILABS_GECKO_RAIL_MULTIPROTOCOL)
      zephyr_compile_definitions(SL_RAIL_LIB_MULTIPROTOCOL_SUPPORT=1)
      add_prebuilt_library(librail platform/radio/rail_lib/autogen/librail_release/librail_multiprotocol_efr32xg${GECKO_SERIES_NUMBER}_gcc_release.a)

    else()
      zephyr_compile_definitions(SL_RAIL_LIB_MULTIPROTOCOL_SUPPORT=0)
      add_prebuilt_library(librail platform/radio/rail_lib/autogen/librail_release/librail_efr32xg${GECKO_SERIES_NUMBER}_gcc_release.a)
    endif()

+6 −0
Original line number Diff line number Diff line
@@ -101,6 +101,12 @@ if(CONFIG_SOC_GECKO_HAS_RADIO)
    endif()
    zephyr_library_sources(${RADIO_DIR}/rail_lib/plugin/pa-conversions/pa_conversions_efr32.c)

    if(CONFIG_SILABS_SISDK_RAIL_MULTIPROTOCOL)
      zephyr_compile_definitions(SL_RAIL_LIB_MULTIPROTOCOL_SUPPORT=1)
    else()
      zephyr_compile_definitions(SL_RAIL_LIB_MULTIPROTOCOL_SUPPORT=0)
    endif()

    if(CONFIG_SILABS_DEVICE_IS_MODULE)
      # RAIL lib and config for modules
      if(CONFIG_SILABS_SISDK_RAIL_MULTIPROTOCOL)
+0 −1
Original line number Diff line number Diff line
@@ -138,7 +138,6 @@
#undef SL_CATALOG_BLUETOOTH_FEATURE_USER_POWER_CONTROL_PRESENT
#undef SL_CATALOG_KERNEL_PRESENT /* Only relevant in the SiSDK RTOS adaptation */
#undef SL_CATALOG_RAIL_UTIL_COEX_PRESENT
#undef SL_RAIL_LIB_MULTIPROTOCOL_SUPPORT

/* Maps the controller configuration options from Kconfig to Silabs defines */
#define SL_BT_CONTROLLER_BUFFER_MEMORY      CONFIG_BT_SILABS_EFR32_BUFFER_MEMORY