mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
b8f682a11b
The tlsf implementation in the ROM does not provide a mechanism to register a callback to be called in by tlsf_check(). This commit is creating a patch of the tlsf implementation to provide a definition of the function allowing to register the callback called in tlsf_check() and add the call of this callback in tlsf_check(). This patch is only compiled for target(s) with ESP_ROM_HAS_HEAP_TLSF set and ESP_ROM_TLSF_CHECK_PATCH set. For all the other configurations the environment remains unchanged by those modifications.
33 lines
685 B
C
33 lines
685 B
C
/*
|
|
* SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
|
*
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*/
|
|
#pragma once
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
/*!
|
|
* @brief Set the function to call for filling memory region when
|
|
* poisoning is configured.
|
|
*
|
|
* @param pfunc The callback function to trigger for poisoning
|
|
* a memory region.
|
|
*/
|
|
void tlsf_poison_fill_pfunc_set(void *pfunc);
|
|
|
|
/*!
|
|
* @brief Set the function to call for checking memory region when
|
|
* poisoning is configured.
|
|
*
|
|
* @param pfunc The callback function to trigger for checking
|
|
* the content of a memory region.
|
|
*/
|
|
void tlsf_poison_check_pfunc_set(void *pfunc);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|