mirror of
https://github.com/espressif/openthread.git
synced 2026-08-01 16:47:47 +00:00
[logging] remove deprecated use of OPENTHREAD_ENABLE_CLI_LOGGING (#2605)
This commit is contained in:
@@ -34,24 +34,13 @@
|
||||
|
||||
#include <openthread-core-config.h>
|
||||
#include <openthread/config.h>
|
||||
|
||||
#include <openthread/cli.h>
|
||||
#include <openthread/platform/logging.h>
|
||||
|
||||
#include "utils/code_utils.h"
|
||||
|
||||
#if (OPENTHREAD_CONFIG_LOG_OUTPUT == OPENTHREAD_CONFIG_LOG_OUTPUT_PLATFORM_DEFINED)
|
||||
void otPlatLog(otLogLevel aLogLevel, otLogRegion aLogRegion, const char *aFormat, ...)
|
||||
{
|
||||
#if OPENTHREAD_ENABLE_CLI_LOGGING
|
||||
va_list args;
|
||||
va_start(args, aFormat);
|
||||
otCliLog(aLogLevel, aLogRegion, aFormat, args);
|
||||
va_end(args);
|
||||
#else
|
||||
(void)aLogLevel;
|
||||
(void)aLogRegion;
|
||||
(void)aFormat;
|
||||
#endif // OPENTHREAD_ENABLE_CLI_LOGGING
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -32,36 +32,15 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "fsl_device_registers.h"
|
||||
#include <stdint.h>
|
||||
|
||||
#include <openthread-core-config.h>
|
||||
#include <openthread/config.h>
|
||||
|
||||
#include "openthread/platform/logging.h"
|
||||
#if OPENTHREAD_ENABLE_CLI_LOGGING
|
||||
#include <ctype.h>
|
||||
#include <inttypes.h>
|
||||
#include <stdarg.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
#include <cli/cli-uart.h>
|
||||
#include <utils/code_utils.h>
|
||||
#endif
|
||||
#include <openthread/platform/logging.h>
|
||||
|
||||
#if (OPENTHREAD_CONFIG_LOG_OUTPUT == OPENTHREAD_CONFIG_LOG_OUTPUT_PLATFORM_DEFINED)
|
||||
void otPlatLog(otLogLevel aLogLevel, otLogRegion aLogRegion, const char *aFormat, ...)
|
||||
{
|
||||
#if OPENTHREAD_ENABLE_CLI_LOGGING
|
||||
va_list args;
|
||||
va_start(args, aFormat);
|
||||
otCliLog(aLogLevel, aLogRegion, aFormat, args);
|
||||
va_end(args);
|
||||
#else
|
||||
(void)aLogLevel;
|
||||
(void)aLogRegion;
|
||||
(void)aFormat;
|
||||
#endif // OPENTHREAD_ENABLE_CLI_LOGGING
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user