OSR 有文章介绍了你用的这种方法,写很具体,去看看吧: Buddy Drivers - Methods for Driver to Driver Communication
http://www.osronline.com/article.cfm?id=24
里面有谈到LZ的这种调用方法. 文章中强调了2点:
1.驱动的加载顺序要正确。DriverA 在通过IoGetDeviceObjectPointer获取DriverB的PDO时,需要确保DriverB已经加载到系统中;
2.文章建议在DriverA调用DriverB时,在DriverA中通过queue a work item来进行IoGetDeviceObjectPointer/IoCallDriver;
蓝屏信息如下(附加了些解释信息):
An attempt was made to touch pageable memory at an IRQL that is too high.
Parameter 1 - Memory referenced.
Parameter 2 - IRQL
Parameter 3 - Value (0=read, 1=write)
Parameter 4 - Address that referenced memory.
解释:
This is a Windows 2000 Executive character-mode STOP message. It indicates an attempt was made to touch pageable memory at a process IRQL (interrupt request level) that is too high. This is usually caused by drivers using incorrect addresses. The fourth parameter in the message parameter list is the memory address at which the fault happened. The second parameter shows the IRQL. If the IRQL was not equal to 2, then the interrupt most likely came from a driver. Compare the memory address in the fourth parameter with the base addresses of the drivers in the driver table on the STOP screen to find the driver that is the problem. Note that the third parameter encodes read/write access (0 = read, 1= write).
请那位大侠帮忙分析下谢谢。
蓝屏信息如下(附加了些解释信息):
An attempt was made to touch pageable memory at an IRQL that is too high.
Parameter 1 - Memory referenced.
Parameter 2 - IRQL
Parameter 3 - Value (0=read, 1=write)
Parameter 4……
蓝屏信息如下(附加了些解释信息):
An attempt was made to touch pageable memory at an IRQL that is too high.
Parameter 1 - Memory referenced.
Parameter 2 - IRQL
Parameter 3 - Value (0=rea……
蓝屏信息如下(附加了些解释信息):
An attempt was made to touch pageable memory at an IRQL that is too high.
Parameter 1 - Memory referenced.
Parameter 2 - IRQL
Parameter 3 - Value (0=rea……
另外,你有办法确认蓝屏到底发生在哪个驱动么?DriverA or DriverB
如果发生在DriverA,那么可能IoCallDriver()能够成功返回,是你某些地方处理不对;
如果发生在DriverB,那么你需要查看DriverB中,对IOCTL_SERIAL_TRANSLATE的处理是否正确,是否有访问越界的地方。如果是这样,把IOCTL_SERIAL_TRANSLATE的处理代码发给大家看看。