summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/powerpc/mbx8xx/console/console.c
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2002-11-04 14:27:49 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2002-11-04 14:27:49 +0000
commit844de9915c5a6568d9f83dba66ccd46777b7b50a (patch)
treef63853649765660a462d314692b58ed052f32f79 /c/src/lib/libbsp/powerpc/mbx8xx/console/console.c
parent4486b180cd7d79f79af0453c6adff9048e1a3060 (diff)
downloadrtems-844de9915c5a6568d9f83dba66ccd46777b7b50a.tar.bz2
2002-11-04 Joel Sherrill <joel@OARcorp.com>
* console/console.c, network/network.c: Removed warnings.
Diffstat (limited to 'c/src/lib/libbsp/powerpc/mbx8xx/console/console.c')
-rw-r--r--c/src/lib/libbsp/powerpc/mbx8xx/console/console.c35
1 files changed, 20 insertions, 15 deletions
diff --git a/c/src/lib/libbsp/powerpc/mbx8xx/console/console.c b/c/src/lib/libbsp/powerpc/mbx8xx/console/console.c
index 8f731058d5..f1ef0c4b4c 100644
--- a/c/src/lib/libbsp/powerpc/mbx8xx/console/console.c
+++ b/c/src/lib/libbsp/powerpc/mbx8xx/console/console.c
@@ -856,12 +856,11 @@ rtems_device_driver console_open(
void *arg
)
{
+#if NVRAM_CONFIGURE == 1
/* Used to track termios private data for callbacks */
extern struct rtems_termios_tty *ttyp[];
-
rtems_libio_open_close_args_t *args = arg;
- rtems_status_code sc;
-
+#endif
static const rtems_termios_callbacks sccEPPCBugCallbacks = {
NULL, /* firstOpen */
NULL, /* lastClose */
@@ -871,29 +870,35 @@ rtems_device_driver console_open(
NULL, /* startRemoteTx */
0 /* outputUsesInterrupts */
};
-
- static const rtems_termios_callbacks intrCallbacks = {
+ static const rtems_termios_callbacks pollCallbacks = {
NULL, /* firstOpen */
NULL, /* lastClose */
- NULL, /* pollRead */
- m8xx_uart_write, /* write */
- m8xx_uart_setAttributes, /* setAttributes */
+ m8xx_uart_pollRead, /* pollRead */
+ m8xx_uart_pollWrite, /* write */
+ m8xx_uart_setAttributes, /* setAttributes */
NULL, /* stopRemoteTx */
NULL, /* startRemoteTx */
- 1 /* outputUsesInterrupts */
+ 0 /* outputUsesInterrupts */
};
+ rtems_status_code sc;
- static const rtems_termios_callbacks pollCallbacks = {
+
+#if (NVRAM_CONFIGURE == 1) || \
+ ((NVRAM_CONFIGURE != 1) && (UARTS_USE_TERMIOS == 1) && \
+ (UARTS_IO_MODE == 1))
+
+ static const rtems_termios_callbacks intrCallbacks = {
NULL, /* firstOpen */
NULL, /* lastClose */
- m8xx_uart_pollRead, /* pollRead */
- m8xx_uart_pollWrite, /* write */
- m8xx_uart_setAttributes, /* setAttributes */
+ NULL, /* pollRead */
+ m8xx_uart_write, /* write */
+ m8xx_uart_setAttributes, /* setAttributes */
NULL, /* stopRemoteTx */
NULL, /* startRemoteTx */
- 0 /* outputUsesInterrupts */
+ 1 /* outputUsesInterrupts */
};
-
+#endif
+
if ( minor > NUM_PORTS-1 )
return RTEMS_INVALID_NUMBER;