jerf.cat
驱动中牛
驱动中牛
  • 注册日期2002-03-30
  • 最后登录2005-09-10
  • 粉丝0
  • 关注0
  • 积分0分
  • 威望0点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
阅读:2354回复:7

Writing Bus Drivers for Windows 2000

楼主#
更多 发布于:2002-05-30 18:47
Writing Bus Drivers for Windows 2000
 OSR Open Systems Resources, Inc.

 

Note:  It is assumed that the reader has some familiarity with Windows 2000, PNP, the concept of Functional Device Objects (FDOs) and Physical Device Objects (PDOs), and of “.INF” files

 

This article is the first in a series of articles on how to write a driver for Windows 2000 that implements the functionality of a bus driver.   A bus driver in Windows 2000 is a driver that manages a “bus” and its associated physical devices.  Of course, this could be a real, honest to goodness, hardware bus.  But what’s really cool about bus drivers is that the “bus” that they manage might not even be any sort of bus, in any conventional sense of the word.  Rather, creating a bus driver will allow one driver to easily connect with and control the number of instances of a higher-level driver in the system.

 

Consider the Microsoft Disk Class driver.  This driver actually acts as both a Function driver and a bus driver.  In its role as a Function driver, it creates a Functional Device Object (FDO) for each disk on the system.  It then proceeds to act as a bus driver, creating a Physical Device Object (PDO) for each partition on each disk.

 

So, bus drivers can really be very useful things in Win2K, when you think about them “right”.  The bus and its devices can be actual physical hardware or virtual hardware, or some abstract software construct.  In each case, the bus driver is responsible for enumerating the bus, handling bus related events (insertions, removals, etc.) and managing power state.  

 

Of course, supporting a new hardware bus will require creating a bus driver.  One of the significant changes in the Windows 2000 architecture was that the bus management functions were removed from the Hardware Abstraction Layer (HAL) and isolated into the bus drivers.  Thus, support for new buses can be added to Win2K without having to change the HAL!

 

For this article, we are going to discuss creating a Virtual Bus driver that supports the mythical Fred Bus.  Our Fred Bus is a virtual bus that supports two virtual devices, the Fred Toaster and Fred Oven devices.  Figure 1 illustrates our bus.

 


 

Figure 1
Dragon2008
驱动中牛
驱动中牛
  • 注册日期2002-04-01
  • 最后登录2006-03-13
  • 粉丝0
  • 关注0
  • 积分31分
  • 威望5点
  • 贡献值0点
  • 好评度1点
  • 原创分0分
  • 专家分0分
沙发#
发布于:2002-05-30 20:37
麻烦翻译一下,我英文不太好。
我姓龙,我属龙,我叫龙。。。
jason.gao
驱动小牛
驱动小牛
  • 注册日期2002-05-08
  • 最后登录2003-11-12
  • 粉丝0
  • 关注0
  • 积分0分
  • 威望0点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
板凳#
发布于:2003-06-12 14:28
为什么不贴原地址

 [url] http://www.osr.com/ntinsider/1999/bus_driver/bus_driver.htm[/url]
我打字很快。
yymrhxf
驱动牛犊
驱动牛犊
  • 注册日期2002-08-07
  • 最后登录2011-10-25
  • 粉丝0
  • 关注0
  • 积分5分
  • 威望4点
  • 贡献值0点
  • 好评度3点
  • 原创分0分
  • 专家分0分
地板#
发布于:2003-06-12 14:52
兄弟,你又为什么不这样贴:

http://www.osr.com/ntinsider_1999.shtml

哈哈,开开玩笑,osr的东西我以前贴过一次,这个再贴一次.
yymrhxf
驱动牛犊
驱动牛犊
  • 注册日期2002-08-07
  • 最后登录2011-10-25
  • 粉丝0
  • 关注0
  • 积分5分
  • 威望4点
  • 贡献值0点
  • 好评度3点
  • 原创分0分
  • 专家分0分
地下室#
发布于:2003-06-12 15:30
通过上面这个链接, 大家可以看到1996到2003 NT INSIDER 所有的免费文章 ,没看过的别错过哦.
lpwnd
驱动小牛
驱动小牛
  • 注册日期2003-03-04
  • 最后登录2012-01-20
  • 粉丝0
  • 关注0
  • 积分2分
  • 威望1点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
5楼#
发布于:2004-04-28 11:11
现在已经看不到了。。。
justincui
驱动牛犊
驱动牛犊
  • 注册日期2004-10-15
  • 最后登录2005-02-19
  • 粉丝0
  • 关注0
  • 积分0分
  • 威望0点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
6楼#
发布于:2005-02-19 12:32
那么现在哪里可以看到NTInsider的文章呢 ?
wowocock
VIP专家组
VIP专家组
  • 注册日期2002-04-08
  • 最后登录2016-01-09
  • 粉丝16
  • 关注2
  • 积分601分
  • 威望1651点
  • 贡献值1点
  • 好评度1227点
  • 原创分1分
  • 专家分0分
7楼#
发布于:2005-02-19 13:30
那么现在哪里可以看到NTInsider的文章呢 ?

记得以前把上面所有的文章都保存下来的,可上次被一个同事给格式化了硬盘,再找已经没了,郁闷的要死......
花开了,然后又会凋零,星星是璀璨的,可那光芒也会消失。在这样 一瞬间,人降生了,笑者,哭着,战斗,伤害,喜悦,悲伤憎恶,爱。一切都只是刹那间的邂逅,而最后都要归入死亡的永眠
游客

返回顶部