mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* Need help making sense of IRQ API
@ 2007-06-29 19:55 LOL ER
  2007-06-29 20:49 ` Michal Schmidt
  0 siblings, 1 reply; 2+ messages in thread
From: LOL ER @ 2007-06-29 19:55 UTC (permalink / raw)
  To: linux-kernel

Hello,
  I've been trying to make sense of how the kernel (on an i386) calls
__do_IRQ() from do_IRQ() for the past few days to no avail. After
doing some research I found out that do_IRQ() calls the corresponding
"highlevel irq-events handler", this lead me to believe that the
kernel calls __do_IRQ through "desc->handle_irq(irq, desc);" (snippet
from do_IRQ in arch/i386). Looking at the kernel I found a comment
which reads, " * @handle_irq: highlevel irq-events handler [if NULL,
__do_IRQ()]", instinctively I then grepped through the kernel to find
any instances of where handle_IRQ is checked for being NULL. I then
found an inlined function called generic_handle_irq that does just
that. If indeed generic_handle_irq() is the default value of
handle_irq(), why is its datatype not irq_flow_handler_t, and where in
the kernel is it set as the default "highlevel irq-events handler?"
Just to clarify what I mean, the handle_irq member in the irq_desc
struct has its datatype as irq_flow_handler_t, which is a function
pointer that takes 2 arguments,  "unsigned int irq, struct irq_desc
*desc", however unsigned generic_handle_irq() takes one argument,
which is just an int representing the IRQ number.
Thank You,
   Robert G.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2007-06-29 20:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-06-29 19:55 Need help making sense of IRQ API LOL ER
2007-06-29 20:49 ` Michal Schmidt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome