summaryrefslogtreecommitdiffstatsabout
diff options
context:
space:
mode:
authorHanhui <sylixos@gmail.com>2019-07-26 06:44:54 (GMT)
committer Hanhui <sylixos@gmail.com>2019-07-15 14:38:40 (GMT)
commitd7983b7d678b33c5373596e619892610dac1f8c1 (patch)
tree0f5965240bf3622dc974d7b5b492762766b4b57d
parent96b2f881b65e2bc4ccb2514a819a2b3cd9d04f09 (diff)
downloadAIC-OS-d7983b7d678b33c5373596e619892610dac1f8c1.zip
Support for TEXT protection with debugging.
-rw-r--r--SylixOS/CHANGELOG3
-rw-r--r--SylixOS/arch/arm/dbg/armDbg.c2
-rw-r--r--SylixOS/arch/arm64/dbg/arm64Dbg.c2
-rw-r--r--SylixOS/arch/c6x/dbg/c6xDbg.c2
-rw-r--r--SylixOS/arch/csky/dbg/cskyDbg.c2
-rw-r--r--SylixOS/arch/mips/dbg/mipsDbg.c2
-rw-r--r--SylixOS/arch/ppc/dbg/ppcDbg.c2
-rw-r--r--SylixOS/arch/riscv/dbg/riscvDbg.c2
-rw-r--r--SylixOS/arch/sparc/dbg/sparcDbg.c2
-rw-r--r--SylixOS/arch/x86/dbg/x86Dbg.c2
-rw-r--r--SylixOS/debug/dtrace/dtrace.c12
-rw-r--r--SylixOS/debug/gdb/gdbserver.c4
-rw-r--r--SylixOS/kernel/core/_ThreadInit.c7
-rw-r--r--SylixOS/kernel/include/k_class.h3
-rw-r--r--SylixOS/kernel/include/k_kernel.h2
-rw-r--r--SylixOS/kernel/vmm/virPage.c6
-rw-r--r--SylixOS/kernel/vmm/vmm.c4
-rw-r--r--SylixOS/kernel/vmm/vmmAbort.c7
-rw-r--r--SylixOS/loader/src/loader.c3
19 files changed, 39 insertions, 30 deletions
diff --git a/SylixOS/CHANGELOG b/SylixOS/CHANGELOG
index a29e14e..99fb109 100644
--- a/SylixOS/CHANGELOG
+++ b/SylixOS/CHANGELOG
@@ -4,6 +4,9 @@ HISTORY
++ New features:
+ 2019-07-26: han.hui
+ 加入 TEXT 段保护与调试断点协同工作支持.
+
2019-07-15: han.hui
加入 mmap 匿名映射的内存预分配机制, 提高 AI 运算效率.
diff --git a/SylixOS/arch/arm/dbg/armDbg.c b/SylixOS/arch/arm/dbg/armDbg.c
index 28a94e8..2d9153c 100644
--- a/SylixOS/arch/arm/dbg/armDbg.c
+++ b/SylixOS/arch/arm/dbg/armDbg.c
@@ -198,7 +198,7 @@ UINT archDbgTrapType (addr_t ulAddr, PVOID pvArch)
if (API_CacheGetOption() & CACHE_TEXT_UPDATE_MP) {
ulCPUId = LW_CPU_GET_CUR_ID();
if (ulLastBpAddr[ulCPUId] == ulAddr) { /* 不是断点的停止 */
- ulLastBpAddr[ulCPUId] = (addr_t)PX_ERROR; /* 同一地址连续失效 */
+ ulLastBpAddr[ulCPUId] = LW_GDB_ADDR_INVAL; /* 同一地址连续失效 */
return (LW_TRAP_INVAL);
} else {
diff --git a/SylixOS/arch/arm64/dbg/arm64Dbg.c b/SylixOS/arch/arm64/dbg/arm64Dbg.c
index 19df355..3828ffb 100644
--- a/SylixOS/arch/arm64/dbg/arm64Dbg.c
+++ b/SylixOS/arch/arm64/dbg/arm64Dbg.c
@@ -178,7 +178,7 @@ UINT archDbgTrapType (addr_t ulAddr, PVOID pvArch)
if (API_CacheGetOption() & CACHE_TEXT_UPDATE_MP) {
ulCPUId = LW_CPU_GET_CUR_ID();
if (ulLastBpAddr[ulCPUId] == ulAddr) { /* 不是断点的停止 */
- ulLastBpAddr[ulCPUId] = (addr_t)PX_ERROR; /* 同一地址连续失效 */
+ ulLastBpAddr[ulCPUId] = LW_GDB_ADDR_INVAL; /* 同一地址连续失效 */
return (LW_TRAP_INVAL);
} else {
diff --git a/SylixOS/arch/c6x/dbg/c6xDbg.c b/SylixOS/arch/c6x/dbg/c6xDbg.c
index 9481c91..44c6f5d 100644
--- a/SylixOS/arch/c6x/dbg/c6xDbg.c
+++ b/SylixOS/arch/c6x/dbg/c6xDbg.c
@@ -178,7 +178,7 @@ UINT archDbgTrapType (addr_t ulAddr, PVOID pvArch)
if (API_CacheGetOption() & CACHE_TEXT_UPDATE_MP) {
ulCPUId = LW_CPU_GET_CUR_ID();
if (ulLastBpAddr[ulCPUId] == ulAddr) { /* 不是断点的停止 */
- ulLastBpAddr[ulCPUId] = (addr_t)PX_ERROR; /* 同一地址连续失效 */
+ ulLastBpAddr[ulCPUId] = LW_GDB_ADDR_INVAL; /* 同一地址连续失效 */
return (LW_TRAP_INVAL);
} else {
diff --git a/SylixOS/arch/csky/dbg/cskyDbg.c b/SylixOS/arch/csky/dbg/cskyDbg.c
index 13e3adf..bf4988c 100644
--- a/SylixOS/arch/csky/dbg/cskyDbg.c
+++ b/SylixOS/arch/csky/dbg/cskyDbg.c
@@ -173,7 +173,7 @@ UINT archDbgTrapType (addr_t ulAddr, PVOID pvArch)
if (API_CacheGetOption() & CACHE_TEXT_UPDATE_MP) {
ulCPUId = LW_CPU_GET_CUR_ID();
if (ulLastBpAddr[ulCPUId] == ulAddr) { /* 不是断点的停止 */
- ulLastBpAddr[ulCPUId] = (addr_t)PX_ERROR; /* 同一地址连续失效 */
+ ulLastBpAddr[ulCPUId] = LW_GDB_ADDR_INVAL; /* 同一地址连续失效 */
return (LW_TRAP_INVAL);
} else {
diff --git a/SylixOS/arch/mips/dbg/mipsDbg.c b/SylixOS/arch/mips/dbg/mipsDbg.c
index 9a88f55..ff586c3 100644
--- a/SylixOS/arch/mips/dbg/mipsDbg.c
+++ b/SylixOS/arch/mips/dbg/mipsDbg.c
@@ -175,7 +175,7 @@ UINT archDbgTrapType (addr_t ulAddr, PVOID pvArch)
if (API_CacheGetOption() & CACHE_TEXT_UPDATE_MP) {
ulCPUId = LW_CPU_GET_CUR_ID();
if (ulLastBpAddr[ulCPUId] == ulAddr) { /* 不是断点的停止 */
- ulLastBpAddr[ulCPUId] = (addr_t)PX_ERROR; /* 同一地址连续失效 */
+ ulLastBpAddr[ulCPUId] = LW_GDB_ADDR_INVAL; /* 同一地址连续失效 */
return (LW_TRAP_INVAL);
} else {
diff --git a/SylixOS/arch/ppc/dbg/ppcDbg.c b/SylixOS/arch/ppc/dbg/ppcDbg.c
index 47df447..78b7e51 100644
--- a/SylixOS/arch/ppc/dbg/ppcDbg.c
+++ b/SylixOS/arch/ppc/dbg/ppcDbg.c
@@ -193,7 +193,7 @@ UINT archDbgTrapType (addr_t ulAddr, PVOID pvArch)
if (API_CacheGetOption() & CACHE_TEXT_UPDATE_MP) {
ulCPUId = LW_CPU_GET_CUR_ID();
if (ulLastBpAddr[ulCPUId] == ulAddr) { /* 不是断点的停止 */
- ulLastBpAddr[ulCPUId] = (addr_t)PX_ERROR; /* 同一地址连续失效 */
+ ulLastBpAddr[ulCPUId] = LW_GDB_ADDR_INVAL; /* 同一地址连续失效 */
return (LW_TRAP_INVAL);
} else {
diff --git a/SylixOS/arch/riscv/dbg/riscvDbg.c b/SylixOS/arch/riscv/dbg/riscvDbg.c
index 01ab183..fd4286d 100644
--- a/SylixOS/arch/riscv/dbg/riscvDbg.c
+++ b/SylixOS/arch/riscv/dbg/riscvDbg.c
@@ -173,7 +173,7 @@ UINT archDbgTrapType (addr_t ulAddr, PVOID pvArch)
if (API_CacheGetOption() & CACHE_TEXT_UPDATE_MP) {
ulCPUId = LW_CPU_GET_CUR_ID();
if (ulLastBpAddr[ulCPUId] == ulAddr) { /* 不是断点的停止 */
- ulLastBpAddr[ulCPUId] = (addr_t)PX_ERROR; /* 同一地址连续失效 */
+ ulLastBpAddr[ulCPUId] = LW_GDB_ADDR_INVAL; /* 同一地址连续失效 */
return (LW_TRAP_INVAL);
} else {
diff --git a/SylixOS/arch/sparc/dbg/sparcDbg.c b/SylixOS/arch/sparc/dbg/sparcDbg.c
index 1eeeca3..0627154 100644
--- a/SylixOS/arch/sparc/dbg/sparcDbg.c
+++ b/SylixOS/arch/sparc/dbg/sparcDbg.c
@@ -175,7 +175,7 @@ UINT archDbgTrapType (addr_t ulAddr, PVOID pvArch)
if (API_CacheGetOption() & CACHE_TEXT_UPDATE_MP) {
ulCPUId = LW_CPU_GET_CUR_ID();
if (ulLastBpAddr[ulCPUId] == ulAddr) { /* 不是断点的停止 */
- ulLastBpAddr[ulCPUId] = (addr_t)PX_ERROR; /* 同一地址连续失效 */
+ ulLastBpAddr[ulCPUId] = LW_GDB_ADDR_INVAL; /* 同一地址连续失效 */
return (LW_TRAP_INVAL);
} else {
diff --git a/SylixOS/arch/x86/dbg/x86Dbg.c b/SylixOS/arch/x86/dbg/x86Dbg.c
index 897505f..fe5f45c 100644
--- a/SylixOS/arch/x86/dbg/x86Dbg.c
+++ b/SylixOS/arch/x86/dbg/x86Dbg.c
@@ -174,7 +174,7 @@ UINT archDbgTrapType (addr_t ulAddr, PVOID pvArch)
if (API_CacheGetOption() & CACHE_TEXT_UPDATE_MP) {
ulCPUId = LW_CPU_GET_CUR_ID();
if (ulLastBpAddr[ulCPUId] == ulAddr) { /* 不是断点的停止 */
- ulLastBpAddr[ulCPUId] = (addr_t)PX_ERROR; /* 同一地址连续失效 */
+ ulLastBpAddr[ulCPUId] = LW_GDB_ADDR_INVAL; /* 同一地址连续失效 */
return (LW_TRAP_INVAL);
} else {
diff --git a/SylixOS/debug/dtrace/dtrace.c b/SylixOS/debug/dtrace/dtrace.c
index 5cca0ec..fdfd533 100644
--- a/SylixOS/debug/dtrace/dtrace.c
+++ b/SylixOS/debug/dtrace/dtrace.c
@@ -269,7 +269,7 @@ INT API_DtraceBreakTrap (addr_t ulAddr, UINT uiBpType)
if (uiBpType == LW_TRAP_ABORT) { /* 恢复终止点指令 */
archDbgApRemove(ulAddr, ptcbCur->TCB_ulAbortPointInst);
ptcbCur->TCB_ulAbortPointInst = 0;
- ptcbCur->TCB_ulAbortPointAddr = 0;
+ ptcbCur->TCB_ulAbortPointAddr = LW_GDB_ADDR_INVAL;
}
dtm.DTM_ulAddr = ulAddr;
@@ -1145,7 +1145,7 @@ ULONG API_DtraceDelBreakInfo (PVOID pvDtrace,
if (ulThread) {
if (__dtraceReadMsgEx(pdtrace, &dtm, LW_TRUE, ulThread) == ERROR_NONE) {
if ((ulBreakAddr == dtm.DTM_ulAddr) ||
- ((ulBreakAddr == (addr_t)PX_ERROR) && (dtm.DTM_uiType == LW_TRAP_ISTEP))) {
+ ((ulBreakAddr == LW_GDB_ADDR_INVAL) && (dtm.DTM_uiType == LW_TRAP_ISTEP))) {
__dtraceReadMsgEx(pdtrace, &dtm, LW_FALSE, ulThread);
if (bContinue) {
API_ThreadContinue(ulThread);
@@ -1313,7 +1313,7 @@ ULONG API_DtraceThreadStepSet (PVOID pvDtrace, LW_OBJECT_HANDLE ulThread, add
return (EINVAL);
}
- if (ulAddr != (addr_t)PX_ERROR) {
+ if (ulAddr != LW_GDB_ADDR_INVAL) {
archDbgBpPrefetch(ulAddr); /* 预先产生相关页面中断 */
}
@@ -1336,7 +1336,7 @@ ULONG API_DtraceThreadStepSet (PVOID pvDtrace, LW_OBJECT_HANDLE ulThread, add
ptcb = _K_ptcbTCBIdTable[usIndex];
#ifdef __DTRACE_DEBUG
- if (ulAddr == (addr_t)PX_ERROR) {
+ if (ulAddr == LW_GDB_ADDR_INVAL) {
__DTRACE_MSG("[DTRACE] <GDB> Pre-Clear thread 0x%lx Step-Breakpoint @ 0x%08lx.\r\n",
ulThread, ptcb->TCB_ulStepAddr);
@@ -1417,7 +1417,7 @@ VOID API_DtraceSchedHook (LW_OBJECT_HANDLE ulThreadOld, LW_OBJECT_HANDLE ulTh
usIndex = _ObjectGetIndex(ulThreadOld);
ptcb = __GET_TCB_FROM_INDEX(usIndex);
- if (ptcb && (ptcb->TCB_ulStepAddr != (addr_t)PX_ERROR) && !ptcb->TCB_bStepClear) {
+ if (ptcb && (ptcb->TCB_ulStepAddr != LW_GDB_ADDR_INVAL) && !ptcb->TCB_bStepClear) {
archDbgBpRemove(ptcb->TCB_ulStepAddr, sizeof(addr_t),
ptcb->TCB_ulStepInst, (LW_CFG_GDB_SMP_TU_LAZY) ? LW_TRUE : LW_FALSE);
ptcb->TCB_bStepClear = LW_TRUE; /* 单步断点已经被清除 */
@@ -1427,7 +1427,7 @@ VOID API_DtraceSchedHook (LW_OBJECT_HANDLE ulThreadOld, LW_OBJECT_HANDLE ulTh
usIndex = _ObjectGetIndex(ulThreadNew);
ptcb = __GET_TCB_FROM_INDEX(usIndex);
- if ((ptcb->TCB_ulStepAddr != (addr_t)PX_ERROR) && ptcb->TCB_bStepClear) {
+ if ((ptcb->TCB_ulStepAddr != LW_GDB_ADDR_INVAL) && ptcb->TCB_bStepClear) {
archDbgBpInsert(ptcb->TCB_ulStepAddr, sizeof(addr_t),
&ptcb->TCB_ulStepInst, LW_TRUE); /* 仅更新本地 I-CACHE */
ptcb->TCB_bStepClear = LW_FALSE; /* 单步断点生效 */
diff --git a/SylixOS/debug/gdb/gdbserver.c b/SylixOS/debug/gdb/gdbserver.c
index f77fb34..fa1cced 100644
--- a/SylixOS/debug/gdb/gdbserver.c
+++ b/SylixOS/debug/gdb/gdbserver.c
@@ -191,7 +191,7 @@ static VOID gdbClearStepMode (LW_GDB_PARAM *pparam, LW_OBJECT_HANDLE ulThread)
API_DtraceThreadStepSet(pparam->GDB_pvDtrace, ulThread, LW_FALSE);
#else
- API_DtraceThreadStepSet(pparam->GDB_pvDtrace, ulThread, (addr_t)PX_ERROR);
+ API_DtraceThreadStepSet(pparam->GDB_pvDtrace, ulThread, LW_GDB_ADDR_INVAL);
#endif /* LW_DTRACE_HW_ISTEP */
}
/*********************************************************************************************************
@@ -238,7 +238,7 @@ static BOOL gdbIsStepBp (LW_GDB_PARAM *pparam, PLW_DTRACE_MSG pdmsg)
static VOID gdbRemoveStepBp (LW_GDB_PARAM *pparam, LW_OBJECT_HANDLE ulThread)
{
#ifdef LW_DTRACE_HW_ISTEP
- API_DtraceDelBreakInfo(pparam->GDB_pvDtrace, ulThread, (addr_t)PX_ERROR, LW_TRUE);
+ API_DtraceDelBreakInfo(pparam->GDB_pvDtrace, ulThread, LW_GDB_ADDR_INVAL, LW_TRUE);
#else
addr_t addrNP;
diff --git a/SylixOS/kernel/core/_ThreadInit.c b/SylixOS/kernel/core/_ThreadInit.c
index 7a1876c..152c420 100644
--- a/SylixOS/kernel/core/_ThreadInit.c
+++ b/SylixOS/kernel/core/_ThreadInit.c
@@ -296,9 +296,10 @@ VOID _TCBBuild (UINT8 ucPriority,
#endif
#if LW_CFG_GDB_EN > 0
- ptcb->TCB_ulStepAddr = (addr_t)PX_ERROR;
- ptcb->TCB_ulStepInst = 0ul;
- ptcb->TCB_bStepClear = LW_TRUE;
+ ptcb->TCB_ulStepAddr = LW_GDB_ADDR_INVAL;
+ ptcb->TCB_ulStepInst = 0ul;
+ ptcb->TCB_bStepClear = LW_TRUE;
+ ptcb->TCB_ulAbortPointAddr = LW_GDB_ADDR_INVAL;
#endif /* LW_CFG_GDB_EN > 0 */
#if LW_CFG_THREAD_NOTE_PAD_EN > 0 /* 任务记事本 */
diff --git a/SylixOS/kernel/include/k_class.h b/SylixOS/kernel/include/k_class.h
index 03c9966..6ba4cd9 100644
--- a/SylixOS/kernel/include/k_class.h
+++ b/SylixOS/kernel/include/k_class.h
@@ -694,12 +694,13 @@ typedef struct __lw_tcb {
*********************************************************************************************************/
#if LW_CFG_GDB_EN > 0
+#define LW_GDB_ADDR_INVAL ((addr_t)PX_ERROR) /* 无效地址 */
addr_t TCB_ulStepAddr; /* 单步地址,-1 表示非单步模式 */
ULONG TCB_ulStepInst; /* 单步地址指令备份 */
BOOL TCB_bStepClear; /* 单步断点是否被清除 */
addr_t TCB_ulAbortPointAddr; /* 终止点地址 */
ULONG TCB_ulAbortPointInst; /* 终止点地址指令备份 */
-#endif
+#endif /* LW_CFG_GDB_EN > 0 */
/*********************************************************************************************************
TCB 权限管理扩展
diff --git a/SylixOS/kernel/include/k_kernel.h b/SylixOS/kernel/include/k_kernel.h
index d9d0eec..1cc890a 100644
--- a/SylixOS/kernel/include/k_kernel.h
+++ b/SylixOS/kernel/include/k_kernel.h
@@ -51,7 +51,7 @@
#define __SYLIXOS_MAJOR_VER 1
#define __SYLIXOS_MINOR_VER 10
-#define __SYLIXOS_PATCH_VER 3
+#define __SYLIXOS_PATCH_VER 4
#define __SYLIXOS_PATCH_PAD 0
/*********************************************************************************************************
diff --git a/SylixOS/kernel/vmm/virPage.c b/SylixOS/kernel/vmm/virPage.c
index cc689bd..26bb0b8 100644
--- a/SylixOS/kernel/vmm/virPage.c
+++ b/SylixOS/kernel/vmm/virPage.c
@@ -47,7 +47,7 @@ static LW_VMM_ZONE _G_vmzoneVirDev;
/*********************************************************************************************************
切换通道
*********************************************************************************************************/
-static addr_t _G_ulVmmSwitchAddr = (addr_t)PX_ERROR;
+static addr_t _G_ulVmmSwitchAddr = PAGE_MAP_ADDR_INV;
/*********************************************************************************************************
** 函数名称: __vmmVirtualDesc
** 功能描述: 获得虚拟空间区域.
@@ -171,7 +171,7 @@ ULONG __vmmVirtualCreate (LW_MMU_VIRTUAL_DESC pvirdes[])
/* 目前不支持 NULL 起始地址 */
if (ulZone < LW_CFG_VMM_VIR_NUM) {
_G_vmvirDescApp[ulZone] = pvirdes[i];
- if (_G_ulVmmSwitchAddr == (addr_t)PX_ERROR) {
+ if (_G_ulVmmSwitchAddr == PAGE_MAP_ADDR_INV) {
_G_ulVmmSwitchAddr = pvirdes[i].VIRD_ulVirAddr;
ulAddr = _G_ulVmmSwitchAddr + LW_CFG_VMM_PAGE_SIZE;
@@ -216,7 +216,7 @@ ULONG __vmmVirtualCreate (LW_MMU_VIRTUAL_DESC pvirdes[])
}
}
- _BugHandle((_G_ulVmmSwitchAddr == (addr_t)PX_ERROR), LW_TRUE,
+ _BugHandle((_G_ulVmmSwitchAddr == PAGE_MAP_ADDR_INV), LW_TRUE,
"virtual switich page invalidate.\r\n");
return (ERROR_NONE);
diff --git a/SylixOS/kernel/vmm/vmm.c b/SylixOS/kernel/vmm/vmm.c
index 5f3fec0..e5f3b66 100644
--- a/SylixOS/kernel/vmm/vmm.c
+++ b/SylixOS/kernel/vmm/vmm.c
@@ -250,7 +250,7 @@ ULONG API_VmmLibAddPhyRam (addr_t ulPhyRam, size_t stSize)
ulPageNum = (ULONG)(stSize >> LW_CFG_VMM_PAGE_SHIFT);
phydesc[0].PHYD_ulPhyAddr = ulPhyRam;
- phydesc[0].PHYD_ulVirMap = (addr_t)PX_ERROR;
+ phydesc[0].PHYD_ulVirMap = PAGE_MAP_ADDR_INV;
phydesc[0].PHYD_stSize = stSize;
phydesc[0].PHYD_uiType = LW_PHYSICAL_MEM_APP;
phydesc[1].PHYD_stSize = 0;
@@ -828,7 +828,7 @@ ULONG API_VmmZoneStatus (ULONG ulZoneIndex,
}
if (pulPgd) {
#if LW_CFG_VMM_L4_HYPERVISOR_EN > 0
- *pulPgd = (addr_t)PX_ERROR;
+ *pulPgd = PAGE_MAP_ADDR_INV;
#else
*pulPgd = (addr_t)pmmuctx->MMUCTX_pgdEntry;
#endif /* !LW_CFG_VMM_L4_HYPERVISOR_EN */
diff --git a/SylixOS/kernel/vmm/vmmAbort.c b/SylixOS/kernel/vmm/vmmAbort.c
index 7d61b2a..042daa2 100644
--- a/SylixOS/kernel/vmm/vmmAbort.c
+++ b/SylixOS/kernel/vmm/vmmAbort.c
@@ -293,7 +293,12 @@ static INT __vmmAbortWriteProtect (PLW_VMM_PAGE pvmpageVirtual,
if ((ulAbortAddr >= pvmpagep->PAGEP_ulPtStart) ||
(ulAbortAddr < (pvmpagep->PAGEP_ulPtStart + pvmpagep->PAGEP_stPtSize))) {
if (ptcbCur->TCB_pvVProcessContext) { /* 进程内修改保护段 */
- return (PX_ERROR); /* 杀死任务, 内存不可写 */
+#if LW_CFG_GDB_EN > 0
+ if (ptcbCur->TCB_ulAbortPointAddr == LW_GDB_ADDR_INVAL)
+#endif /* LW_CFG_GDB_EN */
+ {
+ return (PX_ERROR); /* 杀死任务, 内存不可写 */
+ }
}
}
}
diff --git a/SylixOS/loader/src/loader.c b/SylixOS/loader/src/loader.c
index 5641f6a..1629822 100644
--- a/SylixOS/loader/src/loader.c
+++ b/SylixOS/loader/src/loader.c
@@ -544,7 +544,7 @@ static INT __moduleArchCheck (LW_LD_EXEC_MODULE *pmodule)
}
pringTemp = _list_ring_get_next(pringTemp);
- } while (pringTemp != &pmodule->EMOD_ringModules); /* 查找 libvpmpdm.so fpu设置 */
+ } while (pringTemp != &pmodule->EMOD_ringModules); /* 查找 libvpmpdm.so fpu 设置 */
if (LW_NULL == ppcBaseFpuType) {
LW_VP_UNLOCK(pmodule->EMOD_pvproc);
@@ -662,7 +662,6 @@ static INT finiArrayCall (LW_LD_EXEC_MODULE *pmodule, BOOL bRunFini)
if (__moduleTreeFindSym(pmodTemp, "__c6x_call_internal_func",
&ulValue, LW_LD_SYM_FUNCTION, 20)) {
pfuncCallFunc = LW_NULL;
-
} else {
pfuncCallFunc = (VOIDFUNCPTR)ulValue; /* C6x 需要使用此函数析构 */
}