Filter Driver SendNetBufferList called twice (Intruppt)

We have observed a scenario where, Filter Driver module received a two callbacks from NDIs for handling data through SendNetBufferList where First callback have not completed processing it.

Can you advice how NDIS handles interrupts, and Is is possible to get a send callback while filter driver is processing anther send callback received from NDIS, If it is possible, Is there a way for Filter Driver to indicate to NDIS that, We will only be processing the callbacks sequentially.

When NDIS sends two callbacks at the same time, How does the context switch occur between these two intruppts.

Appreciate your help.

NDIS does not serialize the datapath at all – that’s the job of your filter.

The datapath can run in parallel (on multiple processors or threads); and it can preempt itself (due to IRQL). The simplest thing you can do is to acquire a spinlock whenever calling into your driver, but you can’t do this without understanding the system, as you must not hold that lock while calling out of your driver.

It’s not really correct to talk about interrupts in a filter driver. Hardware interrupts are handled internally by the NIC driver. (Or not – some NICs don’t use traditional CPU interrupts, like USB NICs.) Your filter doesn’t directly see or deal with interrupts.