Subject: bin/15251: /dev/dty?? devices, using puc driver, do not work properly with 'cu'
To: None <gnats-bugs@gnats.netbsd.org>
From: Greg A. Woods <woods@weird.com>
List: netbsd-bugs
Date: 01/15/2002 02:24:40
>Number:         15251
>Category:       bin
>Synopsis:       /dev/dty?? devices, using puc driver, do not work properly with 'cu'
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    bin-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Jan 14 23:25:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     Greg A. Woods
>Release:        2001/06/24
>Organization:
Planix, Inc.; Toronto, Ontario; Canada
>Environment:
System: NetBSD 1.5W
Architecture: i386
Machine: i386
>Description:

	/dev/dty?? devices, via puc, do not work properly with 'cu'

	We've installed a Lava Computers DSerial PCI serial ports card
	for use with a modem for UUCP.  Since this system is new enough
	to support /dev/dty?? dial-out devices, I tried them but found
	the change of carrier when the CONNECT message was issued
	triggered a SIGHUP!  (I.e. presumably with a transition of DCD
	from off to on!)

		puc0 at pci0 dev 8 function 0: Lava Computers serial port (com)
		com3 at puc0 port 0: interrupting at irq 9
		com3: ns16550a, working fifo
		puc1 at pci0 dev 8 function 1: Lava Computers serial port (com)
		com4 at puc1 port 0: interrupting at irq 9
		com4: ns16550a, working fifo

	I'm guessing this is a bug in 'cu', though I mention the kernel
	and driver information in case it's relevant.  (Should SIGHUP
	really be sent on trasition of DCD from off to on!?!?!?)

>How-To-Repeat:

# ### configure /etc/uucp/*
# ### edit /etc/uucp/Devices to use "ACU dty03 - 38400 hayes \T"
# ### note phone number has been obscured....

# cu -dddd --parity=none weirdo
/usr/bin/cu: fconn_open: Opening port ACU (speed 38400)
/usr/bin/cu: fconn_set: Changing setting to 1, 2, 2
/usr/bin/cu: fcsend: Writing sleep "A" pause "TE1V1X1Q0S2=255S12=255\r"
/usr/bin/cu: icexpect: Looking for 3 "OK\r"
/usr/bin/cu: icexpect: Got "ATE1V1X1Q0S2=255S12=255\r\r\nOK\r" (found it)
/usr/bin/cu: fcsend: Writing echo-check-on "ATDT/usr/bin/cu: fconn_read: Read 1 "A"
/usr/bin/cu: fconn_read: Read 1 "T"
/usr/bin/cu: fconn_read: Read 1 "D"
/usr/bin/cu: fconn_read: Read 1 "T"
" \T "4165551212/usr/bin/cu: fconn_read: Read 1 "4"
/usr/bin/cu: fconn_read: Read 1 "1"
/usr/bin/cu: fconn_read: Read 1 "6"
/usr/bin/cu: fconn_read: Read 1 "5"
/usr/bin/cu: fconn_read: Read 1 "5"
/usr/bin/cu: fconn_read: Read 1 "5"
/usr/bin/cu: fconn_read: Read 1 "1"
/usr/bin/cu: fconn_read: Read 1 "2"
/usr/bin/cu: fconn_read: Read 1 "1"
/usr/bin/cu: fconn_read: Read 1 "2"
\r/usr/bin/cu: fconn_read: Read 1 "\r"
"
/usr/bin/cu: icexpect: Looking for 7 "CONNECT"
/usr/bin/cu: icexpect: Got "\r\nCONNECT" (found it)
Connected.
 28800/RQ/V34/L/usr/bin/cu: Got hangup signal
/usr/bin/cu: Exit status 0
/usr/bin/cu: fconn_close: Closing connection

Disconnected.


# ### edit /etc/uucp/Devices to use "ACU tty03 - 38400 hayes \T"

$ cu -ddd --parity=none weirdo
/usr/bin/cu: fconn_open: Opening port ACU (speed 38400)
/usr/bin/cu: fconn_set: Changing setting to 1, 2, 2
/usr/bin/cu: fcsend: Writing sleep "A" pause "TE1V1X1Q0S2=255S12=255\r"
/usr/bin/cu: icexpect: Looking for 3 "OK\r"
/usr/bin/cu: icexpect: Got "ATE1V1X1Q0S2=255S12=255\r\r\nOK\r" (found it)
/usr/bin/cu: fcsend: Writing echo-check-on "ATDT/usr/bin/cu: fconn_read: Read 1 "A"
/usr/bin/cu: fconn_read: Read 1 "T"
/usr/bin/cu: fconn_read: Read 1 "D"
/usr/bin/cu: fconn_read: Read 1 "T"
" \T "4165551212/usr/bin/cu: fconn_read: Read 1 "4"
/usr/bin/cu: fconn_read: Read 1 "1"
/usr/bin/cu: fconn_read: Read 1 "6"
/usr/bin/cu: fconn_read: Read 1 "5"
/usr/bin/cu: fconn_read: Read 1 "5"
/usr/bin/cu: fconn_read: Read 1 "5"
/usr/bin/cu: fconn_read: Read 1 "1"
/usr/bin/cu: fconn_read: Read 1 "2"
/usr/bin/cu: fconn_read: Read 1 "1"
/usr/bin/cu: fconn_read: Read 1 "2"
\r/usr/bin/cu: fconn_read: Read 1 "\r"
"
/usr/bin/cu: icexpect: Looking for 7 "CONNECT"
/usr/bin/cu: icexpect: Got "\r\nCONNECT" (found it)
Connected.
 28800/RQ/V34/LAPM/V42BIS


BSD (weird.com) (tty03)

login: /usr/bin/cu: fconn_write: Writing 1 "\004"
/usr/bin/cu: Got hangup signal
/usr/bin/cu: Exit status 0
/usr/bin/cu: fconn_close: Closing connection

Disconnected.


>Fix:

	unknown

>Release-Note:
>Audit-Trail:
>Unformatted: