public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* IRQ number question.
@ 2018-09-03 17:16 Rogier Wolff
  2018-09-03 18:09 ` Alan Cox
  0 siblings, 1 reply; 4+ messages in thread
From: Rogier Wolff @ 2018-09-03 17:16 UTC (permalink / raw)
  To: linux-kernel

Hi, 

I'm writing a kernel driver. It is not going to be widely used, so I'm
not motivated to make things nice enough for inclusion in the standard
kernel.

But lspci shows my device: 

03:01.0 Serial bus controller [0c80]: Phoenix Contact GmbH & Co. Device 0002 (rev b7)
        Flags: bus master, stepping, medium devsel, latency 32, IRQ 14
        I/O ports at e070 [size=16]
        Memory at f7d00000 (32-bit, non-prefetchable) [size=256K]

Now when I start my module and prod the device a bit, it will generate
an interrupt. (in this case the monitor program needs to start sending
messages to the card.)

Then the kernel reports: 

irq 18: nobody cared (try booting with the "irqpoll" option)

I've been writing device drivers in the past, but in the past
when the lspci listed "IRQ 14" then I'd have to request_irq (14, ...

Has this changed? Or is this hardware "odd"/"bad"/"broken" in that it
initializes the PCI devices wrong? (*)

My driver now works with the interrupts coming in nicely on IRQ18...

I have this card where I'm writing my own driver, and another PCI card
that uses an "included-in-the-kernel" driver, and it too behaves as if
it doesn't get any interrupts.

	Roger. 

(*) Obviously according to everybody "windows works", so could it be
that modern windows simply activates an irq and polls to see what
driver handles it? Or something like that? Ah! That would be somewhat
similar to what "irqpoll" does on Linux!

-- 
** R.E.Wolff@BitWizard.nl ** http://www.BitWizard.nl/ ** +31-15-2600998 **
**    Delftechpark 26 2628 XH  Delft, The Netherlands. KVK: 27239233    **
*-- BitWizard writes Linux device drivers for any device you may have! --*
The plan was simple, like my brother-in-law Phil. But unlike
Phil, this plan just might work.

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

end of thread, other threads:[~2018-09-04  7:40 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-09-03 17:16 IRQ number question Rogier Wolff
2018-09-03 18:09 ` Alan Cox
2018-09-03 19:24   ` Rogier Wolff
2018-09-04  7:40   ` Rogier Wolff

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