[uptime] enable uptime by default on posix and simulation (#7052)

This commit enables OPENTHREAD_CONFIG_UPTIME_ENABLE and
OPENTHREAD_CONFIG_LOG_PREPEND_UPTIME by default on posix and
simulation platforms.
This commit is contained in:
Simon Lin
2021-10-12 12:02:19 -07:00
committed by GitHub
parent c36c0e77a2
commit d39fce1fa6
3 changed files with 41 additions and 0 deletions
+1
View File
@@ -372,6 +372,7 @@ jobs:
REFERENCE_DEVICE: 1
THREAD_VERSION: 1.1
VIRTUAL_TIME: 1
CXXFLAGS: "-DOPENTHREAD_CONFIG_LOG_PREPEND_UPTIME=0"
steps:
- uses: actions/checkout@v2
with:
@@ -212,4 +212,24 @@
#define OPENTHREAD_CONFIG_MLE_INFORM_PREVIOUS_PARENT_ON_REATTACH 1
#endif
/**
* @def OPENTHREAD_CONFIG_UPTIME_ENABLE
*
* Define to 1 to enable tracking the uptime of OpenThread instance.
*
*/
#ifndef OPENTHREAD_CONFIG_UPTIME_ENABLE
#define OPENTHREAD_CONFIG_UPTIME_ENABLE 1
#endif
/**
* @def OPENTHREAD_CONFIG_LOG_PREPEND_UPTIME
*
* Define as 1 to prepend the current uptime to all log messages.
*
*/
#ifndef OPENTHREAD_CONFIG_LOG_PREPEND_UPTIME
#define OPENTHREAD_CONFIG_LOG_PREPEND_UPTIME 1
#endif
#endif // OPENTHREAD_CORE_SIMULATION_CONFIG_H_
@@ -267,4 +267,24 @@
#define OPENTHREAD_CONFIG_CLI_UART_RX_BUFFER_SIZE 640
#endif
/**
* @def OPENTHREAD_CONFIG_UPTIME_ENABLE
*
* Define to 1 to enable tracking the uptime of OpenThread instance.
*
*/
#ifndef OPENTHREAD_CONFIG_UPTIME_ENABLE
#define OPENTHREAD_CONFIG_UPTIME_ENABLE 1
#endif
/**
* @def OPENTHREAD_CONFIG_LOG_PREPEND_UPTIME
*
* Define as 1 to prepend the current uptime to all log messages.
*
*/
#ifndef OPENTHREAD_CONFIG_LOG_PREPEND_UPTIME
#define OPENTHREAD_CONFIG_LOG_PREPEND_UPTIME 1
#endif
#endif // OPENTHREAD_CORE_POSIX_CONFIG_H_