Serial Communications initialization problem

Richard B. Johnson (root@chaos.analogic.com)
Thu, 10 Dec 1998 11:55:48 -0500 (EST)


There is a problem with the Serial Communications in Linux
Version 2.1.131.

If a previous Operating System or DOS Program turns on the FIFOs
on the UARTs, but does not turn them OFF when it exits, the machine
must be powered off before they will work in Linux.

On my system, the two UARTS are properly identified upon startup:

`dmesg`

[SNIPPED]
Starting kswapd v 1.5
parport0: PC-style at 0x378 [SPP,PS2,EPP]
Serial driver version 4.26 with no serial options enabled
ttyS00 at 0x03f8 (irq = 4) is a 16550A
ttyS01 at 0x02f8 (irq = 3) is a 16550A
pty: 256 Unix98 ptys configured
Floppy drive(s): fd0 is 1.44M
[SNIPPED]

Setserial is executed during SYSV startup and displays both of the
devices names and types.

When /dev/ttyS1 is opened by executing `od /dev/ttyS1`, the proper
interrupt is acquired:

`cat /proc/interrupts`

CPU0 CPU1
0: 90455 90106 IO-APIC-edge timer
1: 2082 2054 IO-APIC-edge keyboard
2: 0 0 XT-PIC cascade
3: 14896 14928 IO-APIC-edge serial
10: 25642 25621 IO-APIC-level eth0
11: 3319 3353 IO-APIC-level BusLogic BT-958
13: 1 0 XT-PIC fpu
NMI: 0
IPI: 0

However, I use this port for a serial mouse when using 'X'. It
does not work. A terminal program, Seyon, cannot read data from
this or the other device either.

The only fix under Linux is to shut down, power off, then restart.

I have verified that if I write a 0 to the FCR (base + 2), to
turn off the FIFO (from DOS debug), before I start Linux, the
serial ports run okay (on my machine). Something like this should
probably be added to the driver initialization code.

Cheers,
Dick Johnson
***** FILE SYSTEM WAS MODIFIED *****
Penguin : Linux version 2.1.131 on an i686 machine (400.59 BogoMips).
Warning : It's hard to remain at the trailing edge of technology.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/