!157 fix: comment error

Merge pull request !157 from kenneth/los_backtrace.h2
This commit is contained in:
openharmony_ci 2021-06-04 14:44:56 +08:00 committed by Gitee
commit af9b9ee7fe
2 changed files with 6 additions and 6 deletions

View File

@ -119,7 +119,7 @@ STATIC INLINE UINT32 OsStackAddrGet(UINTPTR *stackStart, UINTPTR *stackEnd, UINT
LosTaskCB *taskCB = OS_TCB_FROM_TID(taskID);
*stackEnd = (UINTPTR)taskCB->topOfStack + taskCB->stackSize;
if ((SP < (UINTPTR)taskCB->topOfStack) || (SP >= *stackEnd)) {
PRINT_ERR("msp statck [0x%x, 0x%x], cur task stack [0x%x, 0x%x], cur sp(0x%x) is overflow!\n",
PRINT_ERR("msp stack [0x%x, 0x%x], cur task stack [0x%x, 0x%x], cur sp(0x%x) is overflow!\n",
CODE_START_ADDR, CSTACK_END_ADDR, (UINTPTR)taskCB->topOfStack, *stackEnd, SP);
return LOS_NOK;
}

View File

@ -46,7 +46,7 @@ extern "C" {
#if (LOSCFG_BACKTRACE_TYPE != 0)
#if (LOSCFG_BACKTRACE_TYPE == 1)
/* The default name of the code section and CSTACK section are given below,
and the user can be adjust it according to the linker script file. */
and the user can adjust it according to the linker script file. */
#if defined(__ICCARM__)
/* The default code section name is .text */
#define CODE_SECTION_NAME ".text"
@ -91,9 +91,9 @@ extern CHAR *CODE_SECTION_END(CODE_SECTION_NAME);
#define CSTACK_START_ADDR ((UINTPTR)&CSTACK_SECTION_START(CSTACK_SECTION_NAME))
#define CSTACK_END_ADDR ((UINTPTR)&CSTACK_SECTION_END(CSTACK_SECTION_NAME))
#elif defined(__GNUC__)
/* The defalut code section start address */
/* The default code section start address */
#define CODE_SECTION_START _stext
/* The defalut code section end address */
/* The default code section end address */
#define CODE_SECTION_END _etext
/* The default C stack section start address */
#define CSTACK_SECTION_START _sstack
@ -117,9 +117,9 @@ extern CHAR *CSTACK_SECTION_END;
#endif
#elif (LOSCFG_BACKTRACE_TYPE == 2)
#if defined(__GNUC__)
/* The defalut code section start address */
/* The default code section start address */
#define CODE_SECTION_START __text_start
/* The defalut code section end address */
/* The default code section end address */
#define CODE_SECTION_END __text_end
extern CHAR *CODE_SECTION_START;