pthread: Remove pthread TLS cleanup dependency on FreeRTOS Static Task Cleanup Hook

This commit removes the need to define the vTaskCleanupTCB hook in
pthread to cleanup the thread-specific data before a thread is deleted.
This commit is contained in:
Sudeep Mohanty
2022-10-31 10:02:03 +01:00
parent 8416f0f540
commit b3755b751e
12 changed files with 90 additions and 83 deletions

View File

@@ -120,7 +120,7 @@ Thread-Specific Data
* ``pthread_key_delete()``
* ``pthread_setspecific()`` / ``pthread_getspecific()``
.. note:: These functions can be called from tasks created using either pthread or FreeRTOS APIs
.. note:: These functions can be called from tasks created using either pthread or FreeRTOS APIs. When calling these functions from tasks created using FreeRTOS APIs, :ref:`CONFIG_FREERTOS_TLSP_DELETION_CALLBACKS` config option must be enabled to ensure the thread-specific data is cleaned up before the task is deleted.
.. note:: There are other options for thread local storage in ESP-IDF, including options with higher performance. See :doc:`/api-guides/thread-local-storage`.