Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 10 Apr 2013 10:28:38 +0400
From:      Lev Serebryakov <lev@FreeBSD.org>
To:        John Baldwin <jhb@freebsd.org>
Cc:        Adrian Chadd <adrian@freebsd.org>, freebsd-current@freebsd.org, Poul-Henning Kamp <phk@phk.freebsd.dk>
Subject:   Re: Intel D2500CC motherboard and strange RS232/UART behavior
Message-ID:  <1659145198.20130410102838@serebryakov.spb.ru>
In-Reply-To: <201304091658.22810.jhb@freebsd.org>
References:  <229402991.20130407172016@serebryakov.spb.ru> <201304091608.09257.jhb@freebsd.org> <105818341.20130410004451@serebryakov.spb.ru> <201304091658.22810.jhb@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Hello, John.
You wrote 10 =E0=EF=F0=E5=EB=FF 2013 =E3., 0:58:22:

>>   Problem is, that every uart device now is independent from each
>>   other in good "OOP" style, and it looks like interrupt sharing we
>>   need one interrupt handler per irq (not per device), which will now
>>   about several UARTs. Something like "multiport" device, bot not
>>   exactly.
JB> No, the interrupt code itself will handle shared interrupts (it will
JB> call all handlers).  I think in practice that uart is setting
  And what will happen, if there is two UARTs asserting interrupt in
same time? First one returns "FILTER_HANDLED", will second handler be
called?

  ISA interrupt sharing IS NOT so simple. sio contains a lot of
 obscure code to work.

JB> INTR_EXCL or some such and/or uart doesn't set RF_SHAREABLE when
JB> allocating the IRQ.  It is probably the latter.  You could try just
JB> adding RF_SHAREABLE to the bus_alloc_resource_any() for the IRQ to
JB> uart and see if that fixes it.
        sc->sc_ires =3D bus_alloc_resource_any(dev, SYS_RES_IRQ, &sc->sc_ir=
id,
            RF_ACTIVE | RF_SHAREABLE);

It is here.

--=20
// Black Lion AKA Lev Serebryakov <lev@FreeBSD.org>




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1659145198.20130410102838>