summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhpa <hpa>2001-11-20 04:01:21 +0000
committerhpa <hpa>2001-11-20 04:01:21 +0000
commit59837af7358f4bd216d290fa9158f5d1a53e862f (patch)
treec4656774fe382464cdfee44fe75dbb4f7d0713cd
parent31dd79a3d527fe05f9452be4169e5d43d3b87b20 (diff)
downloadsyslinux-59837af7358f4bd216d290fa9158f5d1a53e862f.tar.gz
Fix parsing of hardware flow control
-rw-r--r--isolinux.asm10
-rw-r--r--ldlinux.asm10
-rw-r--r--pxelinux.asm10
-rw-r--r--syslinux.doc11
4 files changed, 29 insertions, 12 deletions
diff --git a/isolinux.asm b/isolinux.asm
index ab2d18da..e44e0410 100644
--- a/isolinux.asm
+++ b/isolinux.asm
@@ -1186,16 +1186,20 @@ pc_serial: call getint ; "serial" command
jc parse_config_2
call ungetc
call getint
- jnc .valid_baud
- mov ebx,DEFAULT_BAUD ; No baud rate given
+ mov [FlowControl], byte 0 ; Default to no flow control
+ jc .nobaud
.valid_baud:
push ebx
call getint ; Hardware flow control?
jnc .valid_flow
- xor bx,bx ; Default -> no flow control
+ xor bl,bl ; Default -> no flow control
.valid_flow:
mov [FlowControl],bl
pop ebx ; Baud rate
+ jmp short .parse_baud
+.nobaud:
+ mov ebx,DEFAULT_BAUD ; No baud rate given
+.parse_baud:
pop di ; Serial port #
cmp ebx,byte 75
jb parse_config_2 ; < 75 baud == bogus
diff --git a/ldlinux.asm b/ldlinux.asm
index 9fe7c9d7..ecdcf3aa 100644
--- a/ldlinux.asm
+++ b/ldlinux.asm
@@ -1284,16 +1284,20 @@ pc_serial: call getint ; "serial" command
jc parse_config_2
call ungetc
call getint
- jnc .valid_baud
- mov ebx,DEFAULT_BAUD ; No baud rate given
+ mov [FlowControl], byte 0 ; Default to no flow control
+ jc .nobaud
.valid_baud:
push ebx
call getint ; Hardware flow control?
jnc .valid_flow
- xor bx,bx ; Default -> no flow control
+ xor bl,bl ; Default -> no flow control
.valid_flow:
mov [FlowControl],bl
pop ebx ; Baud rate
+ jmp short .parse_baud
+.nobaud:
+ mov ebx,DEFAULT_BAUD ; No baud rate given
+.parse_baud:
pop di ; Serial port #
cmp ebx,byte 75
jb parse_config_2 ; < 75 baud == bogus
diff --git a/pxelinux.asm b/pxelinux.asm
index 7ad4ffca..8d1e5d32 100644
--- a/pxelinux.asm
+++ b/pxelinux.asm
@@ -1001,16 +1001,20 @@ pc_serial: call getint ; "serial" command
jc parse_config_2
call ungetc
call getint
- jnc .valid_baud
- mov ebx,DEFAULT_BAUD ; No baud rate given
+ mov [FlowControl], byte 0 ; Default to no flow control
+ jc .nobaud
.valid_baud:
push ebx
call getint ; Hardware flow control?
jnc .valid_flow
- xor bx,bx ; Default -> no flow control
+ xor bl,bl ; Default -> no flow control
.valid_flow:
mov [FlowControl],bl
pop ebx ; Baud rate
+ jmp short .parse_baud
+.nobaud:
+ mov ebx,DEFAULT_BAUD ; No baud rate given
+.parse_baud:
pop di ; Serial port #
cmp ebx,byte 75
jb parse_config_2 ; < 75 baud == bogus
diff --git a/syslinux.doc b/syslinux.doc
index f3469864..19f87e20 100644
--- a/syslinux.doc
+++ b/syslinux.doc
@@ -208,9 +208,14 @@ SERIAL port [[baudrate] flowcontrol]
to 9600 bps. The serial parameters are hardcoded to be 8
bits, no parity, 1 stop bit.
- "flowcontrol" is a flag (0 = off, 1 = on), to support hardware
- flowcontrol (RTS/CTS). Specifically, SYSLINUX will assert
- DTR and RTS, and will honor incoming CTS.
+ "flowcontrol" is one of the following values:
+
+ Value Flow control RTS DTR CTS DCD
+ 0 None U U I I
+ 1 RTS/CTS A A O I
+ 2 DTR/DCD A A O O
+
+ U = Unchanged A = Asserted I = Ignored O = Observed
For this directive to be guaranteed to work properly, it
should be the first directive in the configuration file.