summaryrefslogtreecommitdiff
path: root/src/idle.c
diff options
context:
space:
mode:
authoremlslxl <[email protected]>2017-09-15 11:02:24 +0800
committeremlslxl <[email protected]>2017-09-15 11:02:24 +0800
commite521decf2eaf88c662fba12b2d9f07b68bd4979c (patch)
treefbc869c77c305ec42044ef81f7756076e9ee8936 /src/idle.c
parent0d193254f8600a36b5df604974beccf7491572e2 (diff)
根据documentation/coding_style_cn.txt约定 对内核src和include目录下的文件代码进行格式化
Diffstat (limited to 'src/idle.c')
-rw-r--r--src/idle.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/idle.c b/src/idle.c
index db87baa484..e268c085a7 100644
--- a/src/idle.c
+++ b/src/idle.c
@@ -55,7 +55,7 @@ static void (*rt_thread_idle_hook)();
/**
* @ingroup Hook
- * This function sets a hook function to idle thread loop. When the system performs
+ * This function sets a hook function to idle thread loop. When the system performs
* idle loop, this hook function should be invoked.
*
* @param hook the specified hook function
@@ -77,7 +77,7 @@ rt_inline int _has_defunct_thread(void)
* into a "if".
*
* So add the volatile qualifier here. */
- const volatile rt_list_t *l = (const volatile rt_list_t*)&rt_thread_defunct;
+ const volatile rt_list_t *l = (const volatile rt_list_t *)&rt_thread_defunct;
return l->next != l;
}
@@ -155,8 +155,8 @@ void rt_thread_idle_excute(void)
rt_module_free((rt_module_t)thread->module_id, thread->stack_addr);
else
#endif
- /* release thread's stack */
- RT_KERNEL_FREE(thread->stack_addr);
+ /* release thread's stack */
+ RT_KERNEL_FREE(thread->stack_addr);
/* delete thread object */
rt_object_delete((rt_object_t)thread);
#endif
@@ -185,12 +185,12 @@ static void rt_thread_idle_entry(void *parameter)
{
while (1)
{
- #ifdef RT_USING_IDLE_HOOK
+#ifdef RT_USING_IDLE_HOOK
if (rt_thread_idle_hook != RT_NULL)
{
rt_thread_idle_hook();
}
- #endif
+#endif
rt_thread_idle_excute();
}