@@ -77,7 +77,7 @@ void rt_thread_inited_sethook(void (*hook)(rt_thread_t thread))
7777#endif /* RT_USING_HOOK */
7878
7979/* must be invoke witch rt_hw_interrupt_disable */
80- static void _rt_thread_cleanup_execute (rt_thread_t thread )
80+ static void _thread_cleanup_execute (rt_thread_t thread )
8181{
8282 register rt_base_t level ;
8383#ifdef RT_USING_MODULE
@@ -101,7 +101,7 @@ static void _rt_thread_cleanup_execute(rt_thread_t thread)
101101 rt_hw_interrupt_enable (level );
102102}
103103
104- static void _rt_thread_exit (void )
104+ static void _thread_exit (void )
105105{
106106 struct rt_thread * thread ;
107107 register rt_base_t level ;
@@ -112,7 +112,7 @@ static void _rt_thread_exit(void)
112112 /* disable interrupt */
113113 level = rt_hw_interrupt_disable ();
114114
115- _rt_thread_cleanup_execute (thread );
115+ _thread_cleanup_execute (thread );
116116
117117 /* remove from schedule */
118118 rt_schedule_remove_thread (thread );
@@ -139,14 +139,14 @@ static void _rt_thread_exit(void)
139139 rt_hw_interrupt_enable (level );
140140}
141141
142- static rt_err_t _rt_thread_init (struct rt_thread * thread ,
143- const char * name ,
144- void (* entry )(void * parameter ),
145- void * parameter ,
146- void * stack_start ,
147- rt_uint32_t stack_size ,
148- rt_uint8_t priority ,
149- rt_uint32_t tick )
142+ static rt_err_t _thread_init (struct rt_thread * thread ,
143+ const char * name ,
144+ void (* entry )(void * parameter ),
145+ void * parameter ,
146+ void * stack_start ,
147+ rt_uint32_t stack_size ,
148+ rt_uint8_t priority ,
149+ rt_uint32_t tick )
150150{
151151 /* init thread list */
152152 rt_list_init (& (thread -> tlist ));
@@ -163,11 +163,11 @@ static rt_err_t _rt_thread_init(struct rt_thread *thread,
163163#ifdef ARCH_CPU_STACK_GROWS_UPWARD
164164 thread -> sp = (void * )rt_hw_stack_init (thread -> entry , thread -> parameter ,
165165 (void * )((char * )thread -> stack_addr ),
166- (void * )_rt_thread_exit );
166+ (void * )_thread_exit );
167167#else
168168 thread -> sp = (void * )rt_hw_stack_init (thread -> entry , thread -> parameter ,
169169 (rt_uint8_t * )((char * )thread -> stack_addr + thread -> stack_size - sizeof (rt_ubase_t )),
170- (void * )_rt_thread_exit );
170+ (void * )_thread_exit );
171171#endif /* ARCH_CPU_STACK_GROWS_UPWARD */
172172
173173 /* priority init */
@@ -274,14 +274,14 @@ rt_err_t rt_thread_init(struct rt_thread *thread,
274274 /* initialize thread object */
275275 rt_object_init ((rt_object_t )thread , RT_Object_Class_Thread , name );
276276
277- return _rt_thread_init (thread ,
278- name ,
279- entry ,
280- parameter ,
281- stack_start ,
282- stack_size ,
283- priority ,
284- tick );
277+ return _thread_init (thread ,
278+ name ,
279+ entry ,
280+ parameter ,
281+ stack_start ,
282+ stack_size ,
283+ priority ,
284+ tick );
285285}
286286RTM_EXPORT (rt_thread_init );
287287
@@ -376,7 +376,7 @@ rt_err_t rt_thread_detach(rt_thread_t thread)
376376 rt_schedule_remove_thread (thread );
377377 }
378378
379- _rt_thread_cleanup_execute (thread );
379+ _thread_cleanup_execute (thread );
380380
381381 /* release thread timer */
382382 rt_timer_detach (& (thread -> thread_timer ));
@@ -440,7 +440,7 @@ rt_thread_t rt_thread_create(const char *name,
440440 return RT_NULL ;
441441 }
442442
443- _rt_thread_init (thread ,
443+ _thread_init (thread ,
444444 name ,
445445 entry ,
446446 parameter ,
@@ -479,7 +479,7 @@ rt_err_t rt_thread_delete(rt_thread_t thread)
479479 rt_schedule_remove_thread (thread );
480480 }
481481
482- _rt_thread_cleanup_execute (thread );
482+ _thread_cleanup_execute (thread );
483483
484484 /* release thread timer */
485485 rt_timer_detach (& (thread -> thread_timer ));
0 commit comments