[BSP] remove rt_device_init_all() invoking.

This commit is contained in:
bernard 2014-07-19 06:50:00 +08:00
parent a8224dcb82
commit 26118499e0
31 changed files with 15 additions and 139 deletions

View File

@ -138,8 +138,6 @@ void rt_init_thread_entry(void* parameter)
/* register ethernetif device */
eth_system_device_init();
rt_hw_macb_init();
/* re-init device driver */
rt_device_init_all();
/* init lwip system */
lwip_sys_init();
}

View File

@ -39,7 +39,6 @@ int main(void)
#endif
rt_system_scheduler_init();
rt_device_init_all();
rt_application_init();
#ifdef RT_USING_FINSH

View File

@ -62,9 +62,6 @@ void rtthread_startup(void)
RT_DEVICE_FLAG_RDWR | RT_DEVICE_FLAG_INT_RX | RT_DEVICE_FLAG_STREAM,
&uart0);
/* init all device */
rt_device_init_all();
rt_console_set_device("uart0");
#endif

View File

@ -114,9 +114,6 @@ void rtthread_startup(void)
/* init scheduler system */
rt_system_scheduler_init();
/* init all devices */
rt_device_init_all();
/* init finsh */
#ifdef RT_USING_FINSH
finsh_system_init();

View File

@ -118,8 +118,6 @@ void rtthread_startup(void)
/* init sd card device */
rt_hw_sdcard_init();
#endif
/* init all device */
rt_device_init_all();
/* init application */
rt_application_init();

View File

@ -118,8 +118,6 @@ void rtthread_startup(void)
/* init sd card device */
rt_hw_sdcard_init();
#endif
/* init all device */
rt_device_init_all();
/* init application */
rt_application_init();

View File

@ -118,8 +118,6 @@ void rtthread_startup(void)
/* init sd card device */
rt_hw_sdcard_init();
#endif
/* init all device */
rt_device_init_all();
/* init application */
rt_application_init();

View File

@ -16,20 +16,13 @@
#include <rthw.h>
#include <rtthread.h>
#include "LPC17xx.h"
#include "board.h"
#ifdef RT_USING_DFS
#include "sd.h"
#endif
/**
* @addtogroup LPC17
* @addtogroup LPC176x
*/
/*@{*/
extern int rt_application_init(void);
#include <board.h>
extern int rt_application_init(void);
#ifdef __CC_ARM
extern int Image$$RW_IRAM1$$ZI$$Limit;
@ -84,14 +77,6 @@ void rtthread_startup(void)
/* initialize scheduler system */
rt_system_scheduler_init();
#ifdef RT_USING_DEVICE
#ifdef RT_USING_DFS
rt_hw_sdcard_init();
#endif
/* initialize all device */
rt_device_init_all();
#endif
/* initialize application */
rt_application_init();

View File

@ -65,8 +65,6 @@ void rt_init_thread_entry(void *parameter)
/* register ethernetif device */
lpc17xx_emac_hw_init();
/* init all device */
rt_device_init_all();
/* init lwip system */
lwip_sys_init();
@ -78,13 +76,11 @@ void rt_init_thread_entry(void *parameter)
{
extern void rtgui_system_server_init(void);
extern void application_init(void);
rt_device_t lcd;
/* init lcd */
rt_hw_lcd_init();
/* re-init device driver */
rt_device_init_all();
/* find lcd device */
lcd = rt_device_find("lcd");

View File

@ -100,9 +100,6 @@ void rtthread_startup(void)
/* init hardware serial device */
rt_hw_serial_init();
/*init all registed devices*/
rt_device_init_all();
#endif
/* init application */

View File

@ -33,14 +33,11 @@ void rt_init_thread_entry(void *parameter)
/* init Display Controller */
rt_hw_dc_init();
/* re-init device driver */
rt_device_init_all();
/* find Display Controller device */
dc = rt_device_find("dc");
/* set Display Controller device as rtgui graphic driver */
/* set Display Controller device as rtgui graphic driver */
rtgui_graphic_set_device(dc);
}
#endif
@ -59,7 +56,7 @@ int rt_application_init(void)
tid = rt_thread_create("init",
rt_init_thread_entry, RT_NULL,
4096, 8, 20);
if (tid != RT_NULL)
if (tid != RT_NULL)
rt_thread_startup(tid);
return 0;

View File

@ -64,11 +64,6 @@ void rtthread_startup(void)
/* init scheduler system */
rt_system_scheduler_init();
#ifdef RT_USING_DEVICE
/* init all device */
rt_device_init_all();
#endif
/* init application */
rt_application_init();
@ -85,7 +80,7 @@ void rtthread_startup(void)
rt_system_scheduler_start();
/* never reach here */
return;
return ;
}
/*@}*/

View File

@ -50,7 +50,7 @@ SECTIONS
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
__rt_init_end = .;
. = ALIGN(4);
}

View File

@ -68,11 +68,6 @@ void rtthread_startup(void)
/* init scheduler system */
rt_system_scheduler_init();
#ifdef RT_USING_DEVICE
/* init all device */
rt_device_init_all();
#endif
/* init application */
rt_application_init();

View File

@ -44,10 +44,7 @@ void rt_init_thread_entry(void *parameter)
rt_hw_adc_init();
rt_hw_lcd_init();
rt_hw_cpu_init();
/* re-init device driver */
rt_device_init_all();
#ifdef RT_USING_RTGUI
extern void rtgui_system_server_init(void);

View File

@ -59,13 +59,9 @@ void rtthread_startup(void)
rt_system_scheduler_init();
#ifdef RT_USING_DEVICE
#ifdef RT_USING_DFS
#ifdef RT_USING_DFS_UFFS
#if defined(RT_USING_DFS) && defined(RT_USING_DFS_UFFS)
rt_hw_nand_init();
#endif
#endif
/* initialize all device */
rt_device_init_all();
#endif
/* initialize application */
@ -91,7 +87,7 @@ int main(void)
{
/* disable interrupt first */
rt_hw_interrupt_disable();
/* startup RT-Thread RTOS */
rtthread_startup();

View File

@ -86,8 +86,6 @@ void rtthread_startup(void)
#ifdef RT_USING_DEVICE
/* init hardware serial device */
rt_hw_serial_init();
/* init all device */
rt_device_init_all();
#endif
/* init application */

View File

@ -151,9 +151,6 @@ void rt_init_thread_entry(void *parameter)
/* init keypad */
rt_hw_key_init();
/* re-init device driver */
rt_device_init_all();
/* find lcd device */
lcd = rt_device_find("lcd");
@ -175,9 +172,6 @@ void rt_init_thread_entry(void *parameter)
/* register ethernetif device */
rt_hw_dm9000_init();
/* re-init device driver */
rt_device_init_all();
/* init lwip system */
lwip_sys_init();
rt_kprintf("TCP/IP initialized!\n");
@ -197,9 +191,6 @@ void rt_init_thread_entry(void *parameter)
/* init keypad */
rt_hw_key_init();
/* re-init device driver */
rt_device_init_all();
/* create ftk thread */
ftk_thread = rt_thread_create("ftk",
rt_ftk_thread_entry, RT_NULL,

View File

@ -126,9 +126,6 @@ void rtthread_startup(void)
/* rtc init */
rt_hw_rtc_init();
/*init all registed devices */
rt_device_init_all();
#endif
/* init application */

View File

@ -79,9 +79,6 @@ void rtthread_startup()
eth_system_device_init();
rt_hw_dm9161_init();
#endif
/*init all registed devices */
rt_device_init_all();
#endif
/* init application */
@ -108,10 +105,8 @@ void rtthread_startup()
int main()
{
rt_uint32_t UNUSED level;
/* disable interrupt first */
level = rt_hw_interrupt_disable();
rt_hw_interrupt_disable();
/* startup RT-Thread RTOS */
rtthread_startup();

View File

@ -116,9 +116,6 @@ void rtthread_startup(void)
#ifdef RT_USING_DFS
rt_hw_sdcard_init();
#endif
/*init all registed devices*/
rt_device_init_all();
#endif
/* init application */

View File

@ -78,20 +78,6 @@ void rtthread_startup()
/* init scheduler system */
rt_system_scheduler_init();
#ifdef RT_USING_DEVICE
#ifdef RT_USING_DFS
/* Not implemented */
#endif
#ifdef RT_USING_LWIP
/* Not implemented */
#endif
/*init all registed devices */
rt_device_init_all();
#endif
/* init application */
rt_application_init();

View File

@ -58,10 +58,6 @@ void rtthread_startup(void)
/* init scheduler system */
rt_system_scheduler_init();
/* init all device */
#ifdef RT_USING_DEVICE
rt_device_init_all();
#endif
/* init application */
rt_application_init();

View File

@ -86,11 +86,6 @@ void rtthread_startup(void)
/* init scheduler system */
rt_system_scheduler_init();
#ifdef RT_USING_DEVICE
/* init all device */
rt_device_init_all();
#endif
/* init application */
rt_application_init();

View File

@ -81,9 +81,6 @@ void rtthread_startup(void)
/* init scheduler system */
rt_system_scheduler_init();
/* init all device */
rt_device_init_all();
/* init application */
rt_application_init();

View File

@ -122,9 +122,6 @@ void rt_init_thread_entry(void* parameter)
/* init touch panel */
rtgui_touch_hw_init();
/* re-init device driver */
rt_device_init_all();
/* find lcd device */
lcd = rt_device_find("lcd");

View File

@ -66,12 +66,9 @@ void rt_init_thread_entry(void* parameter)
/* register ethernetif device */
eth_system_device_init();
/* initialize eth interface */
rt_hw_stm32_eth_init();
/* re-init device driver */
rt_device_init_all();
/* init lwip system */
lwip_sys_init();

View File

@ -107,9 +107,6 @@ void rtthread_startup(void)
rt_hw_rtc_init();
/* init all device */
rt_device_init_all();
/* init application */
rt_application_init();

View File

@ -34,8 +34,6 @@ void rt_init_thread_entry(void* parameter)
eth_system_device_init();
rt_hw_stm32_eth_init();
/* re-init device driver */
rt_device_init_all();
/* init lwip system */
lwip_sys_init();

View File

@ -85,9 +85,6 @@ void rtthread_startup(void)
/* init scheduler system */
rt_system_scheduler_init();
/* init all device */
rt_device_init_all();
/* init application */
rt_application_init();

View File

@ -68,11 +68,6 @@ void rtthread_startup(void)
/* init scheduler system */
rt_system_scheduler_init();
#ifdef RT_USING_DEVICE
/* init all device */
rt_device_init_all();
#endif
/* init application */
rt_application_init();