Re: OpenBSD IRQ sharing on ISA

2018-02-08 Thread Eric Furman
On Thu, Feb 8, 2018, at 7:02 AM, Mihai Popescu wrote:
> > Then i setup only one port using configure command all ports work normally.
> 
> I worked a lot with multiple RS-232 ports boards. They all had some
> hardware jumpers to configure the IRQ and Address for each port ( a
> lot of jumpers!). Maybe this option is integrated in your board BIOS,
> check it.
> 
> How did you manage to find and even install 3.8 ?
> 

The question is not how it is why. :)
I have sitting next to me every CD going back to 3.3.
If I were to dig a bit I am sure I  could find even earlier ones.



Re: OpenBSD IRQ sharing on ISA

2018-02-08 Thread Nick Holland
On 02/08/18 04:31, Захаров Анатолий wrote:
> I install OpenBSD on my Fastwell CPB905 Singleboard compter. IT have
> 4-RS-232 port on same IRQ, but on different address on isa bus. Then i
> setup only one port using configure command all ports work normally. But
> when i setup 2 of them in one boot configuration i get in dmesg: irq
> already in use. I found next thing in OpenBSD 3.8. documentation:
> 
> ISA devices can not share IRQs. If you find ISA devices sharing IRQs, you
> must correct this problem.
> 
> But how it works on Linux & QNX?

REALLY, if you have to ask such questions, you should not be using 35+
year old HW designs like ISA.  The world is much simpler now, focused on
a less experienced userbase.


The ISA bus was designed for one device, one interrupt.  The OS would
install code to deal with device X on IRQ Y.  When IRQ Y was detected,
the code to handle device X was run and -- BY DEFINITION -- it knew it
could close out the interrupt and get back to whatever else the computer
was doing.  The software was written that way, and the HW was designed
that way -- devices could apply a logic zero or logic one to a IRQ pin.
Start sharing IRQs, you could end up with one card trying to pull the
pin high, another pulling it low (so even if you write fancy software
that polls multiple devices sharing an IRQ, odds are, the HW won't allow
it to work).

Now, there are things that APPEAR to violate this one device, one
interrupt rule.  For example, I have a Boca 8 port serial card in a
machine that has a total of ten serial ports:

boca0 at isa0 port 0x100/64 irq 10
com4 at boca0 slave 0: ns16550a, 16 byte fifo
com5 at boca0 slave 1: ns16550a, 16 byte fifo
com6 at boca0 slave 2: ns16550a, 16 byte fifo
com7 at boca0 slave 3: ns16550a, 16 byte fifo
com8 at boca0 slave 4: ns16550a, 16 byte fifo
com9 at boca0 slave 5: ns16550a, 16 byte fifo
com10 at boca0 slave 6: ns16550a, 16 byte fifo
com11 at boca0 slave 7: ns16550a, 16 byte fifo
com0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
com1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo

In this case, the ENTIRE Boca board is ONE device sharing an IRQ, there
is no violation.  The drivers for it know when it gets called by an IRQ,
it has to poll ALL the devices looking for something that needs to be
done.  It is a Boca driver (which happens to have eight ports), not a
generic ISA COM port driver.  Your system is most likely along these
lines.  Someone wrote the driver for your cluster of serial
ports-as-one-device for other OSs, and you are trying to use the ISA com
port driver on OpenBSD.  Your options are to either write some code
(hint: the boca driver might be a good starting point, but notice that
it is NOT part of the base system ... for a reason!  (that's a custom
compiled kernel I showed a snippet of the dmesg of)

Nick.



Re: OpenBSD IRQ sharing on ISA

2018-02-08 Thread Christer Solskogen
On Thu, Feb 8, 2018 at 1:02 PM, Mihai Popescu  wrote:

>
> How did you manage to find and even install 3.8 ?
>
>
To his defense, he didn't say he installed 3.8. Only what he found
something  in the 3.8 documentation.


Re: OpenBSD IRQ sharing on ISA

2018-02-08 Thread Mihai Popescu
> Then i setup only one port using configure command all ports work normally.

I worked a lot with multiple RS-232 ports boards. They all had some
hardware jumpers to configure the IRQ and Address for each port ( a
lot of jumpers!). Maybe this option is integrated in your board BIOS,
check it.

How did you manage to find and even install 3.8 ?



Re: OpenBSD IRQ sharing on ISA

2018-02-08 Thread Peter N. M. Hansteen
On Thu, Feb 08, 2018 at 02:31:31PM +0500, ??  wrote:
> I install OpenBSD on my Fastwell CPB905 Singleboard compter. IT have
> 4-RS-232 port on same IRQ, but on different address on isa bus. Then i
> setup only one port using configure command all ports work normally. But
> when i setup 2 of them in one boot configuration i get in dmesg: irq
> already in use. I found next thing in OpenBSD 3.8. documentation:

Oh please, OpenBSD 3.8 was released November 1, 2005. 

It was a supported release until OpenBSD 4.0 hit on November 1, 2006. 

If you want any help at all, *please* get hold of a still-supported release 
(6.1 or 6.2, or even a -current snapshot) and see what happens when you 
expose your hardware to that.

- Peter

-- 
Peter N. M. Hansteen, member of the first RFC 1149 implementation team
http://bsdly.blogspot.com/ http://www.bsdly.net/ http://www.nuug.no/
"Remember to set the evil bit on all malicious network traffic"
delilah spamd[29949]: 85.152.224.147: disconnected after 42673 seconds.



Re: OpenBSD IRQ sharing on ISA

2018-02-08 Thread Theo de Raadt
> I install OpenBSD on my Fastwell CPB905 Singleboard compter. IT have
> 4-RS-232 port on same IRQ, but on different address on isa bus. Then i
> setup only one port using configure command all ports work normally. But
> when i setup 2 of them in one boot configuration i get in dmesg: irq
> already in use. I found next thing in OpenBSD 3.8. documentation:


OpenBSD 3.8?  You are on your own.

> ISA devices can not share IRQs. If you find ISA devices sharing IRQs, you
> must correct this problem.
> 
> But how it works on Linux & QNX?

By making significant and serious compromises.



OpenBSD IRQ sharing on ISA

2018-02-08 Thread Захаров Анатолий
I install OpenBSD on my Fastwell CPB905 Singleboard compter. IT have
4-RS-232 port on same IRQ, but on different address on isa bus. Then i
setup only one port using configure command all ports work normally. But
when i setup 2 of them in one boot configuration i get in dmesg: irq
already in use. I found next thing in OpenBSD 3.8. documentation:

ISA devices can not share IRQs. If you find ISA devices sharing IRQs, you
must correct this problem.

But how it works on Linux & QNX?



Без
вирусов. www.avast.ru

<#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>