X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=common%2Fdevices.c;h=9cc963ac204efbd7c965937ef22fee5f402883ef;hb=ebb86c4ecd37a7701358284e497ca4c6483c7cc5;hp=7c859521a3b9548d07d5e13b66bcb1c68dea2a99;hpb=42dfe7a1844cbad7114038aaf03828acb7a84414;p=u-boot diff --git a/common/devices.c b/common/devices.c index 7c859521a3..9cc963ac20 100644 --- a/common/devices.c +++ b/common/devices.c @@ -26,6 +26,7 @@ #include #include #include +#include #ifdef CONFIG_LOGBUFFER #include #endif @@ -33,6 +34,8 @@ #include #endif +DECLARE_GLOBAL_DATA_PTR; + list_t devlist = 0; device_t *stdio_devices[] = { NULL, NULL, NULL }; char *stdio_names[MAX_FILES] = { "stdin", "stdout", "stderr" }; @@ -122,7 +125,7 @@ int device_deregister(char *devname) device_t *dev = NULL; char temp_names[3][8]; - dev_index=-1; + dev_index = -1; for (i=1; i<=ListNumItems(devlist); i++) { dev = ListGetPtrToItem (devlist, i); if(strcmp(dev->name,devname)==0) { @@ -159,8 +162,6 @@ int device_deregister(char *devname) int devices_init (void) { #ifndef CONFIG_ARM /* already relocated for current ARM implementation */ - DECLARE_GLOBAL_DATA_PTR; - ulong relocation_offset = gd->reloc_off; int i; @@ -194,9 +195,15 @@ int devices_init (void) drv_logbuff_init (); #endif drv_system_init (); +#ifdef CONFIG_SERIAL_MULTI + serial_devices_init (); +#endif #ifdef CONFIG_USB_TTY drv_usbtty_init (); #endif +#ifdef CONFIG_NETCONSOLE + drv_nc_init (); +#endif return (0); }