fix: 内核ERR打印,线程信息,不方便问题定位。

close: #I4DAKM

Signed-off-by: zff <zhangfanfan2@huawei.com>
Change-Id: I10a61d87fa516dcccd5ce0ebca18680a20e2f452
This commit is contained in:
zff 2021-10-11 16:44:48 +08:00
parent fe06d0cbb9
commit 232fec27ac
1 changed files with 2 additions and 2 deletions

View File

@ -32,7 +32,7 @@
#include "los_debug.h" #include "los_debug.h"
#include "stdarg.h" #include "stdarg.h"
#include "los_interrupt.h" #include "los_interrupt.h"
#include "los_task.h"
#if (LOSCFG_KERNEL_PRINTF == 1) #if (LOSCFG_KERNEL_PRINTF == 1)
STATIC const CHAR *g_logString[] = { STATIC const CHAR *g_logString[] = {
@ -91,7 +91,7 @@ INT32 OsLogLevelCheck(INT32 level)
} }
if ((level != LOG_COMMON_LEVEL) && ((level > LOG_EMG_LEVEL) && (level <= LOG_DEBUG_LEVEL))) { if ((level != LOG_COMMON_LEVEL) && ((level > LOG_EMG_LEVEL) && (level <= LOG_DEBUG_LEVEL))) {
PRINTK("[%s]", g_logString[level]); PRINTK("[%s][%s]", g_logString[level], LOS_CurTaskNameGet());
} }
return LOS_OK; return LOS_OK;