ISR not received

It’s my first time to develop an entire driver on Windows 8 from the beginning.
The WDF driver is for a multimedia PCI device. BAR0 is for register access. Interrupt type is MSI.
I’ve registered a ISR routine in WdfInterruptCreate().

However when interrupt happens, my ISR doesn’t get called.

I’ve made an windbg extension so that all registers can be read properly. And from register value, I’m sure interrupt happens.

My questions is: Why the ISR isn’t called? And How can I isolate the root cause step by step?
I’m sure the HW initialization is done properly, and interrupt of HW has been enabled, Masks set properly…

Thanks.

Unless you have a bus analyzer, this is a very bold statement.

As a side note… I don’t think I’ve actually been “sure” of much of anything in engineering in, oh, the past ten or so years. I’ve been “pretty confident”… but “SURE”? Nah. There’s a saying in American English “Only fools are positive” – But I digress.

OK, let’s see if we can help: What types of interrupts does your card support (LBI, MSI, Multiple MSI, MSI-X)? Do you make any registry entries (for example, via your INF file) for your driver to indicate the type of interrupt you expect to receive? Where do you create your WDFINTERRUPT?

Peter
OSR
@OSRDrivers

Thanks Peter.

Sorry for the inaccurate description. When I state “INT happens”, I mean from register status, it’s set. But I’m not sure whether the electrical signal is triggered or not, or BUS received the signal but ISR not get called. That’s what I’m checking now.

Now back to your questions:
The PCI configuration space tells me that the device has MSI capability:
50: CapID 05 MSI Capability
51: NextPtr b0
52: MsgCtrl 64BitCapable MSIEnable MultipleMsgEnable:0 (0x1) MultipleMsgCapable:0 (0x1)
54: MsgAddr feeff00c
58: MsgAddrHi 0
5c: MsData 49b1

Check !idt, my ISR routine is there.

I’ve enabled MSI in registry by following:
http://msdn.microsoft.com/en-us/library/windows/hardware/ff544246(v=vs.85).aspx

Below is my code register ISR routine, it’s registered in AddDevice:

WDF_INTERRUPT_CONFIG interruptConfig;
WDF_INTERRUPT_CONFIG_INIT (&interruptConfig, MyEvtIsr, MyEvtDpc);
interruptConfig.EvtInterruptEnable = MyEvtInterruptEnable;
interruptConfig.EvtInterruptDisable = MyEvtInterruptDisable;
status = WdfInterruptCreate(
device,
&interruptConfig,
WDF_NO_OBJECT_ATTRIBUTES,
&deviceContext->interruptObj);

Well, hmmmm… you ARE making your question more difficult.

Your device certainly appears to have a single MSI enabled, and if you’ve correctly checked the IDT and find yourself connected, then you ARE indeed connected to the interrupt.

I can’t find anything to even quibble with in your code.

Hmmm… is your InterruptEnable function called?

Because if it is, and you believe that your device is indeed generating an interrupt, I’ve got pretty much nothing after that. I’d have to start blaming your hardware.

ANY chance at all of a quick check on a bus analyzer to see if that interrupt is actually being generated?

Peter
OSR
@OSRDrivers