Debian 9 serial multiport card setup

Kernels & Hardware, configuring network, installing services

Debian 9 serial multiport card setup

Postby tovis » 2017-10-29 19:04

For ages I'm using BrainBoxes UC-260 PCI card, starting from Debian 6 (Squeeze).

07:00.0 Multiport serial controller: Brain Boxes Device 0d21 (rev 01)
Subsystem: Brain Boxes Device 0633
Control: I/O+ Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx-
Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
Interrupt: pin A routed to IRQ 20
Region 0: Memory at e9300000 (32-bit, non-prefetchable) [size=128]
Region 1: I/O ports at d000 [size=128]
Region 2: I/O ports at d100 [size=64]
Region 3: I/O ports at d200 [size=16]
Region 4: Memory at e9301000 (32-bit, non-prefetchable) [size=64]
Region 5: Memory at e9302000 (32-bit, non-prefetchable) [size=16]
Capabilities: [40] Power Management version 2
Flags: PMEClk- DSI+ D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-

Now my old setup/recipe does not work.
1. Append to kernel parameters "8250.nr_uarts=8"
After reboot I have got serial nodes up to ttyS7
2. Using lspci output decide port addresses and irq configure /etc/serial.conf
/dev/ttyS4 uart 16550A port 0xd100 irq 20 baud_base 115200 spd_normal skip_test ^fourport
one raw for each port, only port is different.
In Debian 9, using this setup I have got:
$ setserial /dev/ttyS4 -a
Invalid argument
Same for every four ports.
After several hours of work I have got that the /dev/ttyS4 .. 7 is the "Invalid argument itself".
As a "work around" I was clean /etc/serial.conf and used a script started form rc.local:

/bin/setserial /dev/ttyS4 uart 16550A port 0xd100 irq 20 baud_base 115200 spd_normal skip_test ^fourport
/bin/setserial /dev/ttyS4 uart unknown
/bin/setserial /dev/ttyS4 uart 16550A port 0xd100 auto_irq autoconfig

One raw for each port, with the same sequence. The third settings are aimed from BrainBoxes script.
The card start working well - I have got checked using short pins 2-3 of DSUB plug, Also other box as a serial terminal and using minicom (9600 baud w/o handshake).
But the resultsa, what system is reported at least false.

$ setserial /dev/ttyS4 -a
/dev/ttyS4, Line 4, UART: 16750, Port: 0xd100, IRQ: 0
Baud_base: 115200, close_delay: 50, divisor: 0
closing_wait: 3000
Flags: spd_normal skip_test auto_irq

$ sudo cat /proc/tty/driver/serial
serinfo:1.0 driver revision:
0: uart:16550A port:000003F8 irq:4 tx:0 rx:0
1: uart:unknown port:000002F8 irq:3
2: uart:unknown port:000003E8 irq:4
3: uart:unknown port:000002E8 irq:3
4: uart:TI16750 port:0000D100 irq:0 tx:20 rx:12 RTS|DTR
5: uart:TI16750 port:0000D108 irq:0 tx:21 rx:11 RTS|DTR
6: uart:TI16750 port:0000D110 irq:0 tx:21 rx:13 RTS|DTR
7: uart:TI16750 port:0000D118 irq:0 tx:75 rx:39 RTS|CTS|DTR|DSR|CD

As you can mention, my card is using irq 0 !? /proc/interrupts reporting that irq 20 does not used at all.
What is this bug could be? What package should be reported? May be it is kernel? - but on you can not send bug about linux 4.9.0 amd64
Skype: tovis01
User avatar
Posts: 23
Joined: 2005-11-06 13:59
Location: Hungary

Return to System configuration

Who is online

Users browsing this forum: No registered users and 5 guests