From cb92e8450460667a2bf8d7fb7e3716aad1e9936e Mon Sep 17 00:00:00 2001 From: "bernard.xiong" Date: Wed, 31 Mar 2010 23:20:10 +0000 Subject: [PATCH] change the priority level of shell task to 5 when the maximal priority level in system is 8. git-svn-id: https://rt-thread.googlecode.com/svn/trunk@567 bbd45198-f89e-11dd-88c7-29a3b14d5316 --- finsh/shell.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/finsh/shell.c b/finsh/shell.c index 3573781389..18ea6d5865 100644 --- a/finsh/shell.c +++ b/finsh/shell.c @@ -436,10 +436,19 @@ void finsh_system_init() #endif #endif +#if RT_THREAD_PRIORITY_MAX == 8 rt_thread_init(&finsh_thread, "tshell", finsh_thread_entry, RT_NULL, &finsh_thread_stack[0], sizeof(finsh_thread_stack), - 20, 100); + 5, 10); +#else + rt_thread_init(&finsh_thread, + "tshell", + finsh_thread_entry, RT_NULL, + &finsh_thread_stack[0], sizeof(finsh_thread_stack), + 20, 10); +#endif + rt_thread_startup(&finsh_thread); }