Handling PnP Paging Request
The following explains why the DO_POWER_PAGABLE bit must be set on the way down and not on the way up:
The power requirements state that if any lower device object sets the DO_POWER_PAGABLE bit, all higher-level drivers must do the same. If the filter
driver fails to set the DO_POWER_PAGABLE bit prior to sending the paging request IRP down the stack, it could violate this condition as follows:Suppose the filter driver does not set the DO_POWER_PAGABLE bit in its Filter DO before forwarding the paging request IRP to the drivers beneath it
in the driver stack. Next suppose that a lower driver sets the DO_POWER_PAGABLE bit in its own DO. Finally, suppose that prior to the completion
of the IRP by the filter driver a power IRP occurs. At that point, the DO_POWER_PAGABLE bit would be cleared in the Filter DO but would be set in
the DO of the lower-level driver, causing a system crash.It is safe to set the DO_POWER_PAGABLE bit before forwarding a paging request down the stack, because there is no longer an active paging file on
the filter driver's device, and therefore no more paging I/O will occur on it. If the request to remove this paging file succeeds, the filter driver will be done. If the request fails, the filter driver can restore the original state of its flags by simply
clearing the DO_POWER_PAGABLE bit prior to completing the IRP. Because the paging file requests are serialized, there is no danger that some other
thread will have modified this bit since the filter driver last altered it.译文为:电源管理的需求规定了假设一个更低层的设备对象设置了 DO_POWER_PAGABLE 位。那么全部的更高层驱动也必须这么做。假设过滤驱动没有在下发分页的 IRP 之前设置 DO_POWER_PAGABLE
位,它可能违反以下的这些条件:如果过滤驱动没有在下发分页 IRP 之前设置 DO_POWER_PAGABLE 位, 再如果下层驱动设置了自己的设备对象的 DO_POWER_PAGABLE 位。最后,如果在这个过滤驱动的 IRP 完毕之前。一个电源 IRP 发生了。这个时候,DO_POWER_PAGABLE
位将被该过滤驱动清除,但它又被更低层的驱动设置了。就引起了一个系统崩溃。
在一个分页请求下发之前设置 DO_POWER_PAGABLE 位是安全的。由于这里不再有一个活跃的分页文件在这个过滤驱动的设备上,因此也不会有分页 I/O 在上面发生。假设移除这个页面文件的请求成功运行,过滤驱动将会去做,假设请求失败,过滤驱动可以恢复它的标志的原始状态,仅仅须要在完毕这个 IRP
之前简单地清除一下 DO_POWER_PAGABLE 位就可以。由于页面文件请求是序列化的。即使其他线程在过滤驱动最后改变它之后又改动了这个位,这也是没有危急的。
原文链接: http://msdn.microsoft.com/zh-cn/ff554992
Handling PnP Paging Request的更多相关文章
- Unable to handle kernel paging request at virtual address
1.Unable to handle kernel paging request at virtual address 00000000 =====>越出内核地址空间范围,原因是由于使用空NUL ...
- An error occured while handling a json request
修复方法: sudo pip install werkzeug==0.8.3
- spring mvc DispatcherServlet详解之二---request通过Controller获取ModelAndView过程
整个spring mvc的架构如下图所示: 上篇文件讲解了DispatcherServlet通过request获取控制器Controller的过程,现在来讲解DispatcherServletDisp ...
- System Error Codes
很明显,以下的文字来自微软MSDN 链接http://msdn.microsoft.com/en-us/library/windows/desktop/ms681382(v=vs.85).aspx M ...
- mm/memory
/* * linux/mm/memory.c * * Copyright (C) 1991, 1992 Linus Torvalds */ /* * demand-loading started ...
- ExtJS远程数据-本地分页
背景 一般情况下,分页展示是前端只负责展示,后台通过SQL语句实现分页查询.当总数据量在千条以下,适合一次性查询出符合条件的所有数据,让前端页面负责分页也是一种选择. 实例 现通过ExtJS 4扩展类 ...
- Windows 错误代码
Error Messages for Windows http://www.gregorybraun.com/MSWINERR.ZIP Server 4.0 Error Messages Code ...
- [转]Delphi I/O Errors
The following are the Windows API (and former DOS) IO errors, which are also the IO errors often ret ...
- [转]ASP.NET web API 2 OData enhancements
本文转自:https://www.pluralsight.com/blog/tutorials/asp-net-web-api-2-odata-enhancements Along with the ...
随机推荐
- Python(2)-第二天
除法 >>> 8 / 5 1 >>> 8 / 5.0 1.6 >>> 8.0 / 5 1.6 >>> 8 // 5.0 1.0 ...
- Quartz.Net学习笔记(2)-简介
一.Quartz.Net是什么 1.来源 Quartz.Net是一个开源的作业调度框架: 2.下载地址 官网地址:http://www.quartz-scheduler.net/documentati ...
- log4j2异步日志解读(二)AsyncLogger
前文已经讲了log4j2的AsyncAppender的实现[log4j2异步日志解读(一)AsyncAppender],今天我们看看AsyncLogger的实现. 看了这个图,应该很清楚AsyncLo ...
- iOS浏览器不能打开手机QQ客服与指定用户聊天界面
这个问题是我在公司需求的时候遇到的,QQ推广工具网站获取的链接在苹果自带浏览器没法打开到聊天界面,是因为safair在打开到app store的时候把参数给丢了,app store再打开到QQ的时候就 ...
- 主库binlog(master-log)与从库relay-log的关系
主库binlog: # at # :: server id end_log_pos CRC32 COMMIT/*!*/; # at # :: server id end_log_pos CRC32 e ...
- java.lang.NoClassDefFoundError: org/hibernate/validator/internal/engine/DefaultClockProvider
①在springboot的spring-boot-starter-web默认引入了以下依赖: <dependency> <groupId>com.fasterxml.jacks ...
- 计算机网络(二)--HTTP详解
Web相关内容都是存储在Web服务器上,Web服务器上使用的是http协议,因此也被成为http服务器.http的client.server构成了万维网的 基本组件 一.资源 1.URI: 统一资源标 ...
- 【转载】文件上传命令rz和下载命令sz的安装
一.xshell工具简介 Xshell 是一个强大的安全终端模拟软件,它支持SSH1, SSH2, 以及Microsoft Windows 平台的TELNET 协议.其可以在Windows界面下用来访 ...
- mysql (5.7版本)---的配置
1.去到官方网站下载 https://dev.mysql.com/downloads/installer/ 或者直接下载 --> https://dev.mysql.com/get/Down ...
- mysql数据库主从操作记录
master数据库已投入生产一段时间后,做主从复制的操作记录 环境: master库:172.18.237.13slave库:172.18.237.14 mysql版本说明: master:mysql ...