Home
last modified time | relevance | path

Searched refs:taskID (Results 1 – 25 of 132) sorted by relevance

123456

/kernel/liteos_a/kernel/base/mem/common/
Dlos_memstat.c38 LITE_OS_SEC_TEXT_MINOR VOID OsTaskMemUsedInc(UINT32 usedSize, UINT32 taskID) in OsTaskMemUsedInc() argument
40 if (taskID >= LOSCFG_BASE_CORE_TSK_LIMIT) { in OsTaskMemUsedInc()
46 g_tskMemUsedInfo[taskID].memUsed += usedSize; in OsTaskMemUsedInc()
49 LITE_OS_SEC_TEXT_MINOR VOID OsTaskMemUsedDec(UINT32 usedSize, UINT32 taskID) in OsTaskMemUsedDec() argument
51 if (taskID >= LOSCFG_BASE_CORE_TSK_LIMIT) { in OsTaskMemUsedDec()
57 if (g_tskMemUsedInfo[taskID].memUsed < usedSize) { in OsTaskMemUsedDec()
59 OsCurrTaskGet()->taskName, g_tskMemUsedInfo[taskID].memUsed, usedSize); in OsTaskMemUsedDec()
62 g_tskMemUsedInfo[taskID].memUsed -= usedSize; in OsTaskMemUsedDec()
65 LITE_OS_SEC_TEXT_MINOR UINT32 OsTaskMemUsage(UINT32 taskID) in OsTaskMemUsage() argument
67 if (taskID >= LOSCFG_BASE_CORE_TSK_LIMIT) { in OsTaskMemUsage()
[all …]
/kernel/liteos_a/kernel/base/include/
Dlos_memstat_pri.h48 extern VOID OsTaskMemUsedInc(UINT32 usedSize, UINT32 taskID);
49 extern VOID OsTaskMemUsedDec(UINT32 usedSize, UINT32 taskID);
50 extern UINT32 OsTaskMemUsage(UINT32 taskID);
51 extern VOID OsTaskMemClear(UINT32 taskID);
59 extern VOID OsTaskSlabUsedInc(UINT32 usedSize, UINT32 taskID);
60 extern VOID OsTaskSlabUsedDec(UINT32 usedSize, UINT32 taskID);
61 extern UINT32 OsTaskSlabUsage(UINT32 taskID);
65 #define OS_MEM_ADD_USED(usedSize, taskID) OsTaskMemUsedInc(usedSize, taskID) argument
66 #define OS_MEM_REDUCE_USED(usedSize, taskID) OsTaskMemUsedDec(usedSize, taskID) argument
67 #define OS_MEM_CLEAR(taskID) OsTaskMemClear(taskID) argument
[all …]
Dlos_task_pri.h161 #define OS_TSK_GET_INDEX(taskID) (taskID) argument
195 #define OS_TCB_FROM_TID(taskID) (((LosTaskCB *)g_taskCBArray) + (taskID)) argument
246 STATIC INLINE LosTaskCB *OsGetTaskCB(UINT32 taskID) in OsGetTaskCB() argument
248 return OS_TCB_FROM_TID(taskID); in OsGetTaskCB()
266 #define OS_TID_CHECK_INVALID(taskID) ((UINT32)(taskID) >= g_taskMaxNum) argument
301 extern BOOL OsTaskCpuAffiSetUnsafe(UINT32 taskID, UINT16 newCpuAffiMask, UINT16 *oldCpuAffiMask);
308 extern UINT32 OsShellCmdTskInfoGet(UINT32 taskID, VOID *seqfile, UINT16 flag);
312 extern VOID OsTaskEntry(UINT32 taskID);
/kernel/liteos_m/components/security/box/
Dlos_box.c40 VOID OsUserTaskInit(UINT32 taskID, UINTPTR entry, UINTPTR userArea, UINTPTR userSp) in OsUserTaskInit() argument
42 LosTaskCB *taskCB = OS_TCB_FROM_TID(taskID); in OsUserTaskInit()
46 g_UserTaskCBArray[taskID].userArea = userArea; in OsUserTaskInit()
47 g_UserTaskCBArray[taskID].userSp = userSp; in OsUserTaskInit()
48 g_UserTaskCBArray[taskID].boxID = g_UserTaskCBArray[g_losTask.runTask->taskID].boxID; in OsUserTaskInit()
51 VOID OsUserTaskDelete(UINT32 taskID) in OsUserTaskDelete() argument
53 (VOID)memset_s(&g_UserTaskCBArray[taskID], sizeof(UserTaskCB), 0, sizeof(UserTaskCB)); in OsUserTaskDelete()
56 UserTaskCB *OsGetUserTaskCB(UINT32 taskID) in OsGetUserTaskCB() argument
58 return &g_UserTaskCBArray[taskID]; in OsGetUserTaskCB()
74 UINT32 ret, taskID; in OsBoxStart() local
[all …]
Dlos_box.h65 VOID OsUserTaskInit(UINT32 taskID, UINTPTR entry, UINTPTR userArea, UINTPTR userSp);
66 VOID OsUserTaskDelete(UINT32 taskID);
67 UserTaskCB *OsGetUserTaskCB(UINT32 taskID);
/kernel/liteos_m/components/cpup/
Dlos_cpup.c190 UINT32 taskID; in OsTskCycleStart() local
196 taskID = g_losTask.newTask->taskID; in OsTskCycleStart()
197 g_cpup[taskID].cpupID = taskID; in OsTskCycleStart()
198 g_cpup[taskID].startTime = CpupTimeUsGet(); in OsTskCycleStart()
211 UINT32 taskID; in OsTskCycleEnd() local
218 taskID = g_losTask.runTask->taskID; in OsTskCycleEnd()
220 if (g_cpup[taskID].startTime == 0) { in OsTskCycleEnd()
225 if (cpuTime < g_cpup[taskID].startTime) { in OsTskCycleEnd()
229 g_cpup[taskID].allTime += (cpuTime - g_cpup[taskID].startTime); in OsTskCycleEnd()
230 g_cpup[taskID].startTime = 0; in OsTskCycleEnd()
[all …]
/kernel/liteos_m/kernel/src/
Dlos_task.c78 #define OS_TASK_ID_CHECK(taskID) (OS_TSK_GET_INDEX(taskID) < g_taskMaxNum) argument
84 #define OS_CHECK_TSK_PID_NOIDLE(taskID) (OS_TSK_GET_INDEX(taskID) >= g_taskMaxNum) argument
120 STATIC_INLINE UINT32 OsCheckTaskIDValid(UINT32 taskID) in OsCheckTaskIDValid() argument
123 if (taskID == g_idleTaskID) { in OsCheckTaskIDValid()
126 } else if (taskID == g_swtmrTaskID) { in OsCheckTaskIDValid()
129 } else if (OS_TSK_GET_INDEX(taskID) >= g_taskMaxNum) { in OsCheckTaskIDValid()
137 UINT32 taskID = taskCB->taskID; in OsInsertTCBToFreeList() local
139 taskCB->taskID = taskID; in OsInsertTCBToFreeList()
239 UINT32 OsGetTaskWaterLine(UINT32 taskID) in OsGetTaskWaterLine() argument
244 if (*(UINT32 *)(UINTPTR)OS_TCB_FROM_TID(taskID)->topOfStack == OS_TASK_MAGIC_WORD) { in OsGetTaskWaterLine()
[all …]
/kernel/liteos_a/kernel/base/core/
Dlos_task.c101 g_mainTask[i].taskID = LOSCFG_BASE_CORE_TSK_LIMIT; in OsSetMainTask()
148 OsTaskWaitSetPendMask(OS_TASK_WAIT_JOIN, taskCB->taskID, LOS_WAIT_FOREVER); in OsTaskJoinPendUnsafe()
194 g_taskCBArray[index].taskID = index; in OsTaskInit()
250 return runTask->taskID; in LOS_CurTaskIDGet()
313 UINT32 taskID = taskCB->taskID; in OsInsertTCBToFreeList() local
315 taskCB->taskID = taskID; in OsInsertTCBToFreeList()
348 taskCB->processID, taskCB->taskID, mapBase, mapSize, ret); in OsTaskResourcesToFree()
352 LiteIpcRemoveServiceHandle(taskCB->taskID); in OsTaskResourcesToFree()
397 LITE_OS_SEC_TEXT_INIT VOID OsTaskEntry(UINT32 taskID) in OsTaskEntry() argument
399 LOS_ASSERT(!OS_TID_CHECK_INVALID(taskID)); in OsTaskEntry()
[all …]
/kernel/liteos_a/compat/posix/src/
Dsched.c65 UINT32 taskID = (UINT32)pid; in sched_setaffinity() local
73 if (taskID == 0) { in sched_setaffinity()
74 taskID = LOS_CurTaskIDGet(); in sched_setaffinity()
75 if (taskID == LOS_ERRNO_TSK_ID_INVALID) { in sched_setaffinity()
81 ret = LOS_TaskCpuAffiSet(taskID, (UINT16)set->__bits[0]); in sched_setaffinity()
97 UINT32 taskID = (UINT32)pid; in sched_getaffinity() local
105 if (taskID == 0) { in sched_getaffinity()
106 taskID = LOS_CurTaskIDGet(); in sched_getaffinity()
107 if (taskID == LOS_ERRNO_TSK_ID_INVALID) { in sched_getaffinity()
113 cpuAffiMask = LOS_TaskCpuAffiGet(taskID); in sched_getaffinity()
/kernel/liteos_m/components/debugtools/
Dlos_stackdump.c67 STATIC INT32 DumpTaskInfo(UINT32 taskID, UINTPTR *buf, DumpInfo *info) in DumpTaskInfo() argument
70 LosTaskCB *taskCB = OS_TCB_FROM_TID(taskID); in DumpTaskInfo()
72 if (taskID == LOS_CurTaskIDGet()) { in DumpTaskInfo()
92 VOID LOS_TaskStackDump(UINT32 taskID) in LOS_TaskStackDump() argument
99 if (taskID > g_taskMaxNum) { in LOS_TaskStackDump()
100 PRINT_ERR("error taskID %u\r\n", taskID); in LOS_TaskStackDump()
110 info.waterLine = OsGetTaskWaterLine(taskID); in LOS_TaskStackDump()
124 ret = DumpTaskInfo(taskID, buf, &info); in LOS_TaskStackDump()
134 PRINTK("Task %u, SP 0x%x, WaterLine 0x%x", taskID, info.taskSP, info.waterLine); in LOS_TaskStackDump()
143 UINT32 taskID; in OsShellCmdStackDump() local
[all …]
/kernel/liteos_a/kernel/include/
Dlos_task.h592 extern UINT32 LOS_TaskCreateOnly(UINT32 *taskID, TSK_INIT_PARAM_S *initParam);
637 extern UINT32 LOS_TaskCreate(UINT32 *taskID, TSK_INIT_PARAM_S *initParam);
663 extern UINT32 LOS_TaskResume(UINT32 taskID);
692 extern UINT32 LOS_TaskSuspend(UINT32 taskID);
722 extern UINT32 LOS_TaskDelete(UINT32 taskID);
830 extern UINT32 LOS_TaskPriSet(UINT32 taskID, UINT16 taskPrio);
903 extern UINT16 LOS_TaskPriGet(UINT32 taskID);
968 extern UINT32 LOS_TaskInfoGet(UINT32 taskID, TSK_INFO_S *taskInfo);
1014 extern UINT16 LOS_TaskCpuAffiGet(UINT32 taskID);
1034 extern INT32 LOS_GetTaskScheduler(INT32 taskID);
[all …]
/kernel/liteos_m/kernel/include/
Dlos_task.h633 extern UINT32 LOS_TaskCreateOnly(UINT32 *taskID, TSK_INIT_PARAM_S *taskInitParam);
680 extern UINT32 LOS_TaskCreate(UINT32 *taskID, TSK_INIT_PARAM_S *taskInitParam);
706 extern UINT32 LOS_TaskResume(UINT32 taskID);
735 extern UINT32 LOS_TaskSuspend(UINT32 taskID);
763 extern UINT32 LOS_TaskDelete(UINT32 taskID);
870 extern UINT32 LOS_TaskPriSet(UINT32 taskID, UINT16 taskPrio);
943 extern UINT16 LOS_TaskPriGet(UINT32 taskID);
1025 extern UINT32 LOS_TaskInfoGet(UINT32 taskID, TSK_INFO_S *taskInfo);
1047 extern UINT32 LOS_TaskStatusGet(UINT32 taskID, UINT32* taskStatus);
1144 extern CHAR* LOS_TaskNameGet(UINT32 taskID);
[all …]
/kernel/liteos_m/components/security/syscall/
Dpthread_syscall.c49 UINT32 ret, taskID; in SysUserTaskCreate() local
59 ret = LOS_TaskCreateOnly(&taskID, &taskInitParam); in SysUserTaskCreate()
64 OsUserTaskInit(taskID, entry, userArea, userSp); in SysUserTaskCreate()
65 return taskID; in SysUserTaskCreate()
111 OsGetUserTaskCB(runTask->taskID)->userArea = (unsigned long)(uintptr_t)area; in SysSetThreadArea()
123 area = (char *)OsGetUserTaskCB(runTask->taskID)->userArea; in SysGetThreadArea()
/kernel/liteos_a/syscall/
Dprocess_syscall.c928 int SysUserThreadSetDetach(unsigned int taskID) in SysUserThreadSetDetach() argument
933 if (OS_TID_CHECK_INVALID(taskID)) { in SysUserThreadSetDetach()
937 LosTaskCB *taskCB = OS_TCB_FROM_TID(taskID); in SysUserThreadSetDetach()
951 int SysUserThreadDetach(unsigned int taskID) in SysUserThreadDetach() argument
956 if (OS_TID_CHECK_INVALID(taskID)) { in SysUserThreadDetach()
961 ret = OsUserTaskOperatePermissionsCheck(OS_TCB_FROM_TID(taskID)); in SysUserThreadDetach()
967 if (LOS_TaskDelete(taskID) != LOS_OK) { in SysUserThreadDetach()
974 int SysThreadJoin(unsigned int taskID) in SysThreadJoin() argument
979 if (OS_TID_CHECK_INVALID(taskID)) { in SysThreadJoin()
983 LosTaskCB *taskCB = OS_TCB_FROM_TID(taskID); in SysThreadJoin()
[all …]
/kernel/liteos_m/testsuites/sample/kernel/task/
DIt_los_task_123.c43 UINT32 taskID; in TestCase() local
54 ret = LOS_TaskCreate(&taskID, &osTaskInitParam); in TestCase()
59 ret = LOS_TaskDetach(taskID); in TestCase()
62 ret = LOS_TaskDelete(taskID); in TestCase()
DIt_los_task_118.c43 UINT32 taskID; in TestCase() local
56 ret = LOS_TaskCreate(&taskID, &osTaskInitParam); in TestCase()
59 ret = LOS_TaskJoin(taskID, &uwtemp); in TestCase()
63 ret = LOS_TaskDelete(taskID); in TestCase()
DIt_los_task_119.c46 UINT32 taskID; in TestCase() local
57 ret = LOS_TaskCreate(&taskID, &osTaskInitParam); in TestCase()
60 ret = LOS_TaskJoin(taskID, NULL); in TestCase()
65 ret = LOS_TaskDelete(taskID); in TestCase()
DIt_los_task_129.c43 UINT32 taskID; in TestCase() local
58 ret = LOS_TaskCreate(&taskID, &osTaskInitParam); in TestCase()
63 ret = LOS_TaskJoin(taskID, NULL); in TestCase()
66 ret = LOS_TaskDelete(taskID); in TestCase()
/kernel/liteos_m/components/backtrace/
Dlos_backtrace.c86 UINT32 taskID = LOS_CurTaskIDGet(); in OsStackAddrGet() local
87 LosTaskCB *taskCB = OS_TCB_FROM_TID(taskID); in OsStackAddrGet()
107 UINT32 taskID = LOS_CurTaskIDGet(); in OsStackAddrGet() local
108 LosTaskCB *taskCB = OS_TCB_FROM_TID(taskID); in OsStackAddrGet()
112 taskCB->topOfStack, *stackEnd, *stackStart, taskID); in OsStackAddrGet()
295 UINT32 taskID = LOS_CurTaskIDGet(); in OsStackAddrGet() local
296 LosTaskCB *taskCB = OS_TCB_FROM_TID(taskID); in OsStackAddrGet()
315 UINT32 taskID = LOS_CurTaskIDGet(); in OsStackAddrGet() local
316 LosTaskCB *taskCB = OS_TCB_FROM_TID(taskID); in OsStackAddrGet()
320 taskCB->topOfStack, *stackEnd, *stackStart, taskID); in OsStackAddrGet()
[all …]
/kernel/liteos_a/kernel/extended/liteipc/
Dhm_liteipc.c93 STATIC UINT32 GetTid(UINT32 serviceHandle, UINT32 *taskID);
420 LITE_OS_SEC_TEXT STATIC UINT32 GetTid(UINT32 serviceHandle, UINT32 *taskID) in GetTid() argument
427 *taskID = serviceHandle ? serviceHandle : g_cmsTask.taskID; in GetTid()
432 *taskID = g_serviceHandleMap[serviceHandle].taskID; in GetTid()
441 LITE_OS_SEC_TEXT STATIC UINT32 GenerateServiceHandle(UINT32 taskID, HandleStatus status, UINT32 *se… in GenerateServiceHandle() argument
445 *serviceHandle = taskID ? taskID : LOS_CurTaskIDGet(); /* if taskID is 0, return curTaskID */ in GenerateServiceHandle()
446 if (*serviceHandle != g_cmsTask.taskID) { in GenerateServiceHandle()
453 g_serviceHandleMap[i].taskID = taskID; in GenerateServiceHandle()
478 LITE_OS_SEC_TEXT STATIC UINT32 AddServiceAccess(UINT32 taskID, UINT32 serviceHandle) in AddServiceAccess() argument
488 UINT32 processID = OS_TCB_FROM_TID(taskID)->processID; in AddServiceAccess()
[all …]
/kernel/liteos_a/testsuites/kernel/sample/kernel_base/ipc/mux/full/
DIt_los_mutex_026.c55 UINT16 priority = LOS_TaskPriGet(OsCurrTaskGet()->taskID); in TaskDFunc()
77 UINT16 priority = LOS_TaskPriGet(OsCurrTaskGet()->taskID); in TaskCFunc()
101 UINT16 priority = LOS_TaskPriGet(OsCurrTaskGet()->taskID); in TaskBFunc()
173 UINT16 priority = LOS_TaskPriGet(OsCurrTaskGet()->taskID); in TaskAFunc()
180 priority = LOS_TaskPriGet(OsCurrTaskGet()->taskID); in TaskAFunc()
198 priority = LOS_TaskPriGet(OsCurrTaskGet()->taskID); in TaskAFunc()
210 UINT16 priority = LOS_TaskPriGet(OsCurrTaskGet()->taskID); in Testcase()
228 priority = LOS_TaskPriGet(OsCurrTaskGet()->taskID); in Testcase()
DIt_los_mutex_042.c84 UINT16 prio = LOS_TaskPriGet(OsCurrTaskGet()->taskID); in Testcase()
85 g_mainTaskID = OsCurrTaskGet()->taskID; in Testcase()
108 UINT16 priority = LOS_TaskPriGet(OsCurrTaskGet()->taskID); in Testcase()
125 priority = LOS_TaskPriGet(OsCurrTaskGet()->taskID); in Testcase()
138 priority = LOS_TaskPriGet(OsCurrTaskGet()->taskID); in Testcase()
/kernel/liteos_m/components/trace/cnv/
Dtrace_cnv.c140 (muxCB->owner == NULL) ? 0xffffffff : muxCB->owner->taskID); in LOS_TraceMuxPost()
146 (muxCB->owner == NULL) ? 0xffffffff : muxCB->owner->taskID, timeout); in LOS_TraceMuxPend()
152 (muxCB->owner == NULL) ? 0xffffffff : muxCB->owner->taskID); in LOS_TraceMuxDelete()
157 LOS_TRACE(TASK_CREATE, taskCB->taskID, taskCB->taskStatus, taskCB->priority); in LOS_TraceTaskCreate()
162 LOS_TRACE(TASK_PRIOSET, taskCB->taskID, taskCB->taskStatus, taskCB->priority, prio); in LOS_TraceTaskPriModify()
167 LOS_TRACE(TASK_DELETE, taskCB->taskID, taskCB->taskStatus, (UINTPTR)taskCB->stackPointer); in LOS_TraceTaskDelete()
174 LOS_TRACE(TASK_SWITCH, newTask->taskID, runTask->priority, runTask->taskStatus, in LOS_TraceTaskSwitchedIn()
180 LOS_TRACE(TASK_RESUME, taskCB->taskID, taskCB->taskStatus, taskCB->priority); in LOS_TraceTaskResume()
185 LOS_TRACE(TASK_SUSPEND, taskCB->taskID, taskCB->taskStatus, g_losTask.runTask->taskID); in LOS_TraceTaskSuspend()
/kernel/liteos_a/kernel/base/mp/
Dlos_mp.c79 UINT32 taskID = 0; in OsMpCollectTasks() local
83 for (; taskID <= g_taskMaxNum; taskID++) { in OsMpCollectTasks()
84 taskCB = &g_taskCBArray[taskID]; in OsMpCollectTasks()
95 ret = LOS_TaskDelete(taskID); in OsMpCollectTasks()
/kernel/liteos_a/kernel/extended/trace/cnv/
Dtrace_cnv.c141 (muxCB->owner == NULL) ? 0xffffffff : ((LosTaskCB *)muxCB->owner)->taskID); in LOS_TraceMuxPost()
147 (muxCB->owner == NULL) ? 0xffffffff : ((LosTaskCB *)muxCB->owner)->taskID, timeout); in LOS_TraceMuxPend()
153 (muxCB->owner == NULL) ? 0xffffffff : ((LosTaskCB *)muxCB->owner)->taskID); in LOS_TraceMuxDelete()
161 LOS_TRACE(TASK_CREATE, taskCB->taskID, taskCB->taskStatus, param.priority); in LOS_TraceTaskCreate()
172 LOS_TRACE(TASK_PRIOSET, taskCB->taskID, taskCB->taskStatus, param.priority, prio); in LOS_TraceTaskPriModify()
181 LOS_TRACE(TASK_DELETE, taskCB->taskID, taskCB->taskStatus, (UINTPTR)taskCB->stackPointer); in LOS_TraceTaskDelete()
191 LOS_TRACE(TASK_SWITCH, newTask->taskID, runParam.priority, runTask->taskStatus, in LOS_TraceTaskSwitchedIn()
204 LOS_TRACE(TASK_RESUME, taskCB->taskID, taskCB->taskStatus, param.priority); in LOS_TraceTaskResume()
212 LOS_TRACE(TASK_SUSPEND, taskCB->taskID, taskCB->taskStatus, OsCurrTaskGet()->taskID); in LOS_TraceTaskSuspend()
262 LOS_TRACE(IPC_READ_DROP, msg->taskID, msg->processID, msg->type, msg->code, ipcStatus); in LOS_TraceIpcReadDrop()
[all …]

123456