windows驱动开发-基于WDM的PCIe DMA驱动

版权声明:转载请关注我的公众号-青儿创客基地 https://blog.csdn.net/Zhu_Zhu_2009/article/details/81293844

访问MEM IO资源

Mapping Bus-Relative Addresses to Virtual Addresses

连接中断

Servicing Interrupts

Registering an ISR

Using Message-Signaled Interrupts

Removing an ISR

IoConnectInterrupt
MSI必须使用 IoConnectInterruptEx,参考WdmlibIoConnectInterruptEx

#define IoConnectInterruptEx WdmlibIoConnectInterruptEx
NTSTATUS WdmlibIoConnectInterruptEx(
  PIO_CONNECT_INTERRUPT_PARAMETERS Parameters
);

IO_CONNECT_INTERRUPT_PARAMETERS 的构造参考Using the CONNECT_MESSAGE_BASED Version of IoConnectInterruptEx

Using the CONNECT_LINE_BASED Version of IoConnectInterruptEx
Using the CONNECT_FULLY_SPECIFIED Version of IoConnectInterruptEx

DPC

DPC Objects and DPCs
有两种DPC,一种是WDM驱动集成的DpcForIsr,使用方法参考Registering and Queuing a DpcForIsr Routine,第二个是CustomDpc,参考Registering and Queuing a CustomDpc RoutineCustomDpc又分为CustomThreadedDpc和CustomTimerDpc, CustomThreadedDpc参考Threaded DPCsCustomTimerDpc参考KeXxxTimer Routines, KTIMER Objects, and DPCs

猜你喜欢

转载自blog.csdn.net/Zhu_Zhu_2009/article/details/81293844