imbati
驱动牛犊
驱动牛犊
  • 注册日期2001-09-22
  • 最后登录
  • 粉丝0
  • 关注0
  • 积分0分
  • 威望0点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
阅读:1444回复:2

调用IoStartPacket为什么会出现Page Fault错误?

楼主#
更多 发布于:2001-09-28 21:22
在分派例程中调用IoStartPacket时为什么会出现Page Fault错误?开始我在做IO空间读写时从来没出现过这种情况,后来硬件采用设备内存,因此我把设备内存空间映射到核心虚拟地址空间,再做读写操作时问题就来了,怎么回事这是?(NTDDK)
imbati
BSOD
驱动牛犊
驱动牛犊
  • 注册日期2001-09-28
  • 最后登录2004-09-02
  • 粉丝0
  • 关注0
  • 积分0分
  • 威望0点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
沙发#
发布于:2001-09-28 21:48
That means you were touching the paged memory at raised IRQL, probably in your startIo routine.
If you're using memory-map device, make sure you translate the hardware address and map the address to non-paged pool correctly.

If you are using NT 4,
call HalTranslateBusAddress and MmMapIoSpace(..INMEMORY).

If it's a native WDM driver, when receiving the
IRP_MN_START_DEVICE in your DispatchPnp routine, use the translated resource descriptor to map the memory.

Good luck
COOL NDIS
imbati
驱动牛犊
驱动牛犊
  • 注册日期2001-09-22
  • 最后登录
  • 粉丝0
  • 关注0
  • 积分0分
  • 威望0点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
板凳#
发布于:2001-10-03 17:53
It's really a 低级失误.It should be "if(MemIo==NULL) then".
However,I have uncarefully written "if(MemIo=NULL) then"!
But still thank u for ur advice.
imbati
游客

返回顶部