From: Ming Zhang <mingz@ele.uri.edu>
To: Arjan van de Ven <arjan@infradead.org>
Cc: Bryan Henderson <hbryan@us.ibm.com>,
linux-scsi <linux-scsi@vger.kernel.org>
Subject: Re: hwo to adjust interrupt?
Date: Fri, 12 Aug 2005 14:06:37 -0400 [thread overview]
Message-ID: <1123869997.5546.98.camel@localhost.localdomain> (raw)
In-Reply-To: <1123869071.3218.35.camel@laptopd505.fenrus.org>
On Fri, 2005-08-12 at 19:51 +0200, Arjan van de Ven wrote:
> On Fri, 2005-08-12 at 10:35 -0700, Bryan Henderson wrote:
> > >>How much extra work does Linux have to do for each interrupt?
> > >
> > >usually 1 pci mmio read; the rest is negligible.
> >
> > I was hoping you would cater better to my ignorance of how PCI interrupt
> > handling works in Linux.
> >
> > Is it the case that Linux invokes the registered interrupt handler of each
> > of the drivers for the devices that share the interrupt, and each does an
> > mmio read of its device to find out if it had reason to generate an
> > interrupt? So the waste is that extra call, and you're saying the CPU
> > instructions involved are negligible compared to the mmio read?
>
> yes. A function call is like half a cycle (a function pointer call is
> maybe 40) an mmio read is a lot more
a bit off topic, but where u get these information? thx
>
> > Are these level-sensitive interrupts, so that if both devices need service
> > at the same time, they generate just one interrupt and neither device
> > driver call is wasted?
>
> ok this is more complex, but if 2 cards raise it quickly after
> eachother, before the ISR has run, then you only get the handler called
> once afaik.
so it is possible that both card raise intr quicker than isr run, then
both isr will do mmio and go ahead, but then what is
device 1 raise intr
device 2 isr run and not belong to it, so quit, but before it clear intr
and quit
device 2 raise intr
device 1 isr run and handle device 1, then clear intr and quit.
then device 2 intr lost?
or i understand this wrong. :)
ming
>
>
>
next prev parent reply other threads:[~2005-08-12 18:06 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-08-11 22:31 hwo to adjust interrupt? Ming Zhang
2005-08-12 7:14 ` Arjan van de Ven
2005-08-12 13:14 ` Ming Zhang
2005-08-12 16:59 ` Bryan Henderson
2005-08-12 17:04 ` Arjan van de Ven
2005-08-12 17:35 ` Bryan Henderson
2005-08-12 17:45 ` Ming Zhang
2005-08-12 17:51 ` Arjan van de Ven
2005-08-12 18:06 ` Ming Zhang [this message]
2005-08-15 18:47 ` Bryan Henderson
2005-08-15 19:06 ` Ming Zhang
2005-08-12 19:05 ` Ming Zhang
2005-08-12 19:14 ` Matthew Wilcox
2005-08-12 19:27 ` Ming Zhang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1123869997.5546.98.camel@localhost.localdomain \
--to=mingz@ele.uri.edu \
--cc=arjan@infradead.org \
--cc=hbryan@us.ibm.com \
--cc=linux-scsi@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox