Date: Sun, 23 Jul 1995 22:55:16 +0400 (MSD) From: =?KOI8-R?Q?=E1=CE=C4=D2=C5=CA_=FE=C5=D2=CE=CF=D7?= aka "Andrey A. Chernov, Black Mage" <ache@astral.msk.su> To: Bruce Evans <bde@zeta.org.au>, terry@cs.weber.edu Cc: hackers@freebsd.org, harry@hgac.com, jkh@violet.berkeley.edu Subject: Re: dial up at > 9600 baud Message-ID: <dVKif4myC0@astral.msk.su> In-Reply-To: <199507231738.DAA18866@godzilla.zeta.org.au>; from Bruce Evans at Mon, 24 Jul 1995 03:38:28 %2B1000 References: <199507231738.DAA18866@godzilla.zeta.org.au>
next in thread | previous in thread | raw e-mail | index | archive | help
In message <199507231738.DAA18866@godzilla.zeta.org.au> Bruce Evans writes: >>> The problem: initial port speed 9600, getty speed 38400 f.e., >>> port opened on carrier at 9600, modem detects it and set >>> connection to 9600 too, _then_ getty change port speed to 38400 >>> confusing modem completely. >>> >>> I understand that problem solves by locking port on 38400 >>> initially, but it isn't nice solution, getty must able >>> to open port at correct speed setted in its flags. >There's nothing really wrong with setting the initial speed to 38400 >(except 38400 is too slow - why not 115200? :-). Use >`stty 115200 </dev/ttyid*' in /etc/rc.serial. Bruce, as I already says, I understand it, moreover, all ports works in that way on my site, but I was thinking that getty must be able to work right _without_ locked/initial devices settings too (see below). >>I guess I still don't understand how the modem magically detects >>the port speed when the port sets the baud before it says anything >>(like "login: "). >Perhaps getty sometimes writes something before setting the speed. >It does quite a let between the open and setting the speed. I think that getty don't play role here. Most modern modems are able to sense local interface speed somehow, maybe initial connect handshake involved or other tricks, I don't know exactly. I plan to rewrite getty to open device as non-blocked first, set up all termios flags (not speed only can play role on intelligent multipord card), then open device in blocked mode (wait for carrier). But in one moment I realize that while getty waits for carrier, some other dialout application can become active and leave serial speed into unpredictable state. This fact means two things: 1) getty can't work right without setting of initial device, it is mandatory. So getty must open _initial_ device first (for serial lines only, for other lines normal device here), and setup all termios flags on it, then open normal device in blocking mode. 2) We additionly need to restore initial serial settings in sio.c in comhardclose(), i.e. call comparam(com->it_{in,out}) there. I plan to commit proposed changes in near future, if we agree. -- Andrey A. Chernov : And I rest so composedly, /Now, in my bed, ache@astral.msk.su : That any beholder /Might fancy me dead - FidoNet: 2:5020/230.3 : Might start at beholding me, /Thinking me dead. RELCOM Team,FreeBSD Team : E.A.Poe From "For Annie" 1849
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?dVKif4myC0>