diff options
Diffstat (limited to 'nuttx/arch/z80/src/common')
-rw-r--r-- | nuttx/arch/z80/src/common/up_initialize.c | 12 | ||||
-rw-r--r-- | nuttx/arch/z80/src/common/up_internal.h | 22 |
2 files changed, 23 insertions, 11 deletions
diff --git a/nuttx/arch/z80/src/common/up_initialize.c b/nuttx/arch/z80/src/common/up_initialize.c index 1c71fa517..a4659a2e9 100644 --- a/nuttx/arch/z80/src/common/up_initialize.c +++ b/nuttx/arch/z80/src/common/up_initialize.c @@ -1,8 +1,8 @@ /**************************************************************************** * arch/z80/src/common/up_initialize.c * - * Copyright (C) 2007-2009 Gregory Nutt. All rights reserved. - * Author: Gregory Nutt <spudmonkey@racsa.co.cr> + * Copyright (C) 2007-2009, 2012 Gregory Nutt. All rights reserved. + * Author: Gregory Nutt <gnutt@nuttx.org> * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -153,14 +153,18 @@ void up_initialize(void) /* Initialize the serial device driver */ -#ifdef CONFIG_USE_LOWUARTINIT +#ifdef USE_LOWUARTINIT up_lowuartinit(); #endif -#ifdef CONFIG_USE_SERIALDRIVER + /* Initialize the console device driver */ + +#if defined(USE_SERIALDRIVER) up_serialinit(); #elif defined(CONFIG_DEV_LOWCONSOLE) lowconsole_init(); +#elif defined(CONFIG_RAMLOG_CONSOLE) + ramlog_consoleinit(); #endif /* Initialize the netwok */ diff --git a/nuttx/arch/z80/src/common/up_internal.h b/nuttx/arch/z80/src/common/up_internal.h index 2e5afb2e3..919a74353 100644 --- a/nuttx/arch/z80/src/common/up_internal.h +++ b/nuttx/arch/z80/src/common/up_internal.h @@ -69,15 +69,15 @@ /* Determine which (if any) console driver to use */ #if CONFIG_NFILE_DESCRIPTORS == 0 || defined(CONFIG_DEV_LOWCONSOLE) -# undef CONFIG_USE_SERIALDRIVER +# undef USE_SERIALDRIVER # ifdef CONFIG_HAVE_LOWUARTINIT -# define CONFIG_USE_LOWUARTINIT 1 +# define USE_LOWUARTINIT 1 # else -# undef CONFIG_USE_LOWUARTINIT +# undef USE_LOWUARTINIT # endif #elif defined(CONFIG_DEV_CONSOLE) && CONFIG_NFILE_DESCRIPTORS > 0 -# define CONFIG_USE_SERIALDRIVER 1 -# undef CONFIG_USE_LOWUARTINIT +# define USE_SERIALDRIVER 1 +# undef USE_LOWUARTINIT #endif /**************************************************************************** @@ -105,7 +105,7 @@ extern "C" { EXTERN void up_irqinitialize(void); EXTERN int up_timerisr(int irq, FAR chipreg_t *regs); -#ifdef CONFIG_USE_LOWUARTINIT +#ifdef USE_LOWUARTINIT EXTERN void up_lowuartinit(void); #endif @@ -125,7 +125,7 @@ void up_addregion(void); /* Defined in up_serial.c */ -#ifdef CONFIG_USE_SERIALDRIVER +#ifdef USE_SERIALDRIVER EXTERN void up_serialinit(void); #else # define up_serialinit() @@ -139,6 +139,14 @@ EXTERN void lowconsole_init(void); # define lowconsole_init() #endif +/* Defined in drivers/ramlog.c */ + +#ifdef CONFIG_RAMLOG_CONSOLE +extern void ramlog_consoleinit(void); +#else +# define ramlog_consoleinit() +#endif + /* Low level string output */ extern void up_puts(const char *str); |