summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2001-08-16 20:52:05 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2001-08-16 20:52:05 +0000
commitb9ff276c358906706798417185a88f59facb8293 (patch)
tree44b65b0af42ff390259e7f4d82f67af03baafa6d /c/src/lib/libbsp
parentf7691e3b7bce05e8f5d11c126243036cd0ba1343 (diff)
downloadrtems-b9ff276c358906706798417185a88f59facb8293.tar.bz2
2001-08-16 Mike Siers <mikes@poliac.com>
* comm/tty_drv.c, comm/uart.c: Correct some minor cut and paste bugs.
Diffstat (limited to 'c/src/lib/libbsp')
-rw-r--r--c/src/lib/libbsp/i386/shared/ChangeLog4
-rw-r--r--c/src/lib/libbsp/i386/shared/comm/tty_drv.c16
-rw-r--r--c/src/lib/libbsp/i386/shared/comm/uart.c4
3 files changed, 20 insertions, 4 deletions
diff --git a/c/src/lib/libbsp/i386/shared/ChangeLog b/c/src/lib/libbsp/i386/shared/ChangeLog
index 74b499cd49..2aa06bdd4b 100644
--- a/c/src/lib/libbsp/i386/shared/ChangeLog
+++ b/c/src/lib/libbsp/i386/shared/ChangeLog
@@ -1,4 +1,8 @@
+ * comm/tty_drv.c, comm/uart.c: Correct some minor cut and paste bugs.
+
+2001-07-03 Mike Seirs <mike@poliac.com>
+
* comm/tty_drv.c, comm/uart.c, comm/uart.h: Adds the capability
to use task driven serial I/O to ti386 BSPs. This patch leaves thex
default I/O mode to be IRQ. If you want to use task I/O mode,
diff --git a/c/src/lib/libbsp/i386/shared/comm/tty_drv.c b/c/src/lib/libbsp/i386/shared/comm/tty_drv.c
index 502ab6c4f9..fd096fe9a6 100644
--- a/c/src/lib/libbsp/i386/shared/comm/tty_drv.c
+++ b/c/src/lib/libbsp/i386/shared/comm/tty_drv.c
@@ -18,6 +18,18 @@
* MODIFICATION/HISTORY:
*
* $Log$
+ * Revision 1.4 2001/07/03 17:56:32 joel
+ * 2001-07-03 Mike Seirs <mike@poliac.com>
+ *
+ * * comm/tty_drv.c, comm/uart.c, comm/uart.h: Adds the capability
+ * to use task driven serial I/O to ti386 BSPs. This patch leaves thex
+ * default I/O mode to be IRQ. If you want to use task I/O mode,
+ * then the tty_drv.c file needs to be modified. Basically, all
+ * you need to change is the data values of the termios callbacks
+ * structure. This callback structure is used in the tty1_open
+ * and tty2_open functions. The values you need to set are commented
+ * out in the source code.
+ *
* Revision 1.3 2000/12/05 16:37:38 joel
* 2000-12-01 Joel Sherrill <joel@OARcorp.com>
*
@@ -198,7 +210,7 @@ tty1_open(rtems_device_major_number major,
static rtems_termios_callbacks cb =
{
NULL, /* firstOpen */
- tty1_last_close, /* lastClose */
+ NULL, /* lastClose */
BSP_uart_termios_read_com1, /* poll read */
BSP_uart_termios_write_com1, /* write */
tty1_conSetAttr, /* setAttributes */
@@ -488,7 +500,7 @@ tty2_open(rtems_device_major_number major,
static rtems_termios_callbacks cb =
{
NULL, /* firstOpen */
- tty2_last_close, /* lastClose */
+ NULL, /* lastClose */
BSP_uart_termios_read_com2, /* poll read */
BSP_uart_termios_write_com2, /* write */
tty2_conSetAttr, /* setAttributes */
diff --git a/c/src/lib/libbsp/i386/shared/comm/uart.c b/c/src/lib/libbsp/i386/shared/comm/uart.c
index 50554cc142..3d0718cbe7 100644
--- a/c/src/lib/libbsp/i386/shared/comm/uart.c
+++ b/c/src/lib/libbsp/i386/shared/comm/uart.c
@@ -543,8 +543,8 @@ BSP_uart_termios_read_com2(int uart)
char buf[40];
/* read current byte */
- while (( off < sizeof(buf) ) && ( uread(BSP_UART_COM1, LSR) & DR )) {
- buf[off++] = uread(BSP_UART_COM1, RBR);
+ while (( off < sizeof(buf) ) && ( uread(BSP_UART_COM2, LSR) & DR )) {
+ buf[off++] = uread(BSP_UART_COM2, RBR);
}
/* write out data */