From 1987fa2b75253d9f47cde8f4dd593509027147a5 Mon Sep 17 00:00:00 2001 From: Saya Sugiura Date: Mon, 21 Dec 2020 11:40:42 +0900 Subject: doc: Limitation to SIGUSR1 usage on Android Signed-off-by: Saya Sugiura --- doc/dlt_design_specification.md | 7 +++++++ doc/dlt_for_developers.md | 5 +++++ 2 files changed, 12 insertions(+) diff --git a/doc/dlt_design_specification.md b/doc/dlt_design_specification.md index a6df3c5..b5f8cc7 100644 --- a/doc/dlt_design_specification.md +++ b/doc/dlt_design_specification.md @@ -350,6 +350,13 @@ steps are executed: - Store service id in callback table - Store function pointer in callback table +#### Android: Thread termination + +On Android, `pthread_cancel` is not available in bionic. So current +implementation uses *SIGUSR1* and `pthread_kill` to terminate housekeeper +thread. Due to this, application which is linked to DLT library should not +define *SIGUSR1*. + ### Communication between DLT daemon and DLT user library The communication mechanism (IPC) used between DLT daemon and DLT user library diff --git a/doc/dlt_for_developers.md b/doc/dlt_for_developers.md index 931397c..781f6fb 100644 --- a/doc/dlt_for_developers.md +++ b/doc/dlt_for_developers.md @@ -81,6 +81,11 @@ and to TARGET\_LINK\_LIBRARIES: ${DLT_LIBRARIES} ``` +### Limitation + +On Android, definition of `SIGUSR1` in DLT application shall be avoided since +DLT library blocks `SIGUSR1` to terminate housekeeper thread at exit. + ## General Rules for Logging ### Be Smart -- cgit v1.2.1