mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-18 15:47:13 +00:00
feat(bt/bluedroid): Add print and assert when failed to alloc memory
This commit is contained in:
@@ -46,6 +46,7 @@
|
||||
#define OSI_INITIAL_TRACE_LEVEL UC_BT_LOG_OSI_TRACE_LEVEL
|
||||
#define BLUFI_INITIAL_TRACE_LEVEL UC_BT_LOG_BLUFI_TRACE_LEVEL
|
||||
|
||||
// MEMORY
|
||||
#if UC_BT_BLE_DYNAMIC_ENV_MEMORY
|
||||
#define BT_BLE_DYNAMIC_ENV_MEMORY TRUE
|
||||
#define BTC_DYNAMIC_MEMORY TRUE
|
||||
@@ -64,6 +65,19 @@
|
||||
#define BT_BLE_DYNAMIC_ENV_MEMORY FALSE
|
||||
#endif
|
||||
|
||||
#if UC_HEAP_ALLOCATION_FROM_SPIRAM_FIRST
|
||||
#define HEAP_ALLOCATION_FROM_SPIRAM_FIRST TRUE
|
||||
#else
|
||||
#define HEAP_ALLOCATION_FROM_SPIRAM_FIRST FALSE
|
||||
#endif
|
||||
|
||||
#if UC_BT_ABORT_WHEN_ALLOCATION_FAILS
|
||||
#define HEAP_ALLOCATION_FAILS_ABORT TRUE
|
||||
#else
|
||||
#define HEAP_ALLOCATION_FAILS_ABORT FALSE
|
||||
#endif
|
||||
|
||||
// HCI LOG
|
||||
#if UC_BT_HCI_LOG_DEBUG_EN
|
||||
#define BT_HCI_LOG_INCLUDED UC_BT_HCI_LOG_DEBUG_EN
|
||||
#else
|
||||
|
@@ -94,13 +94,26 @@
|
||||
#define UC_BT_BLUFI_ENABLE FALSE
|
||||
#endif
|
||||
|
||||
//MEMORY DEBUG
|
||||
//MEMORY
|
||||
#ifdef CONFIG_BT_BLUEDROID_MEM_DEBUG
|
||||
#define UC_BT_BLUEDROID_MEM_DEBUG TRUE
|
||||
#else
|
||||
#define UC_BT_BLUEDROID_MEM_DEBUG FALSE
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_BT_ALLOCATION_FROM_SPIRAM_FIRST
|
||||
#define UC_HEAP_ALLOCATION_FROM_SPIRAM_FIRST CONFIG_BT_ALLOCATION_FROM_SPIRAM_FIRST
|
||||
#else
|
||||
#define UC_HEAP_ALLOCATION_FROM_SPIRAM_FIRST FALSE
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_BT_ABORT_WHEN_ALLOCATION_FAILS
|
||||
#define UC_BT_ABORT_WHEN_ALLOCATION_FAILS CONFIG_BT_ABORT_WHEN_ALLOCATION_FAILS
|
||||
#else
|
||||
#define UC_BT_ABORT_WHEN_ALLOCATION_FAILS FALSE
|
||||
#endif
|
||||
|
||||
//HCI LOG
|
||||
#ifdef CONFIG_BT_HCI_LOG_DEBUG_EN
|
||||
#define UC_BT_HCI_LOG_DEBUG_EN TRUE
|
||||
#else
|
||||
|
Reference in New Issue
Block a user