zljiao
驱动牛犊
驱动牛犊
  • 注册日期2002-01-23
  • 最后登录2018-05-29
  • 粉丝0
  • 关注0
  • 积分4分
  • 威望20点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
阅读:836回复:1

我是新手,有些低级问题请教各位高手!!!!

楼主#
更多 发布于:2002-02-01 21:23
1。IO请求的地址和字节等参数是通过什么传给驱动程序的呀?
2。中断程序怎么区分不同的中断源呢?
3。Packet-base System DMA和Common Buffer System DMA的
区别是什么呢?

问题比较低级,请朋友帮助!!
谢谢!
WindThruEars
驱动老牛
驱动老牛
  • 注册日期2002-11-17
  • 最后登录2004-07-10
  • 粉丝0
  • 关注0
  • 积分0分
  • 威望0点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
沙发#
发布于:2002-02-02 09:23
1. parameters in the IRP stack of the IRP.

2. That\'s the responsibility of your driver to judge if that\'s an interrupt of your device, especially when your device is sharing IRQ with any other devices. You should be able to read status from your device to judge if the device asserted an interrupt or not.

3. adapted from OSR\'s \"Windows NT device driver development\"

Packet-Based DMA
Packet-Based DMA is by far the most common type of DMA used in standard KMD drivers.In Packet-Based DMA,

driver utilize direct I/O to describe the requestor\'s data buffer. The driver provides the logical address

and length of each physical fragment of the requestor\'s data buffer, and the transfer direction, to the

device. If a device supports scatter/gather, the driver supplies the device with multiple base address and

length pairs per transfer to describe a physically fragmented data buffer. The number of base address and

length pairs that can be provided to a device at one time is device-dependent. Well designed scatter/gather

devices typically allow a driver to specify enough fragments to completely describe an unusaully fragmented

requestor\'s buffer, thus allowing the buffer to be transfered in a single DMA operation.

Devices that do not support scatter/gather can process only a single logical base address and length per DMA

operation. Therefore, such devices would need to perform mulitple DMA operatiosn to transfer a fragmented

data buffer. Setting up and managing these multiple DMA tranfsers can result in significant performance

overhead. To avoid this overhead for non-scatter/gather devices, the NT DMA model provides a facility called

system scatter/gather, This facility used by device to tansfer the entire requestor\'s buffer in one DMA

operation. One common DMA engine used in PCI devices is the AMCC S5933.

Common-Buffer DMA
Common-Buffer DMA operations utilize the same data buffer repeatly for DMA transfers between the host and the

device. The most frequently encountered Common-Buffer architecture is one in which the device and the driver

share a buffer in host memory containing device-specific data structures.

我是假耳朵
游客

返回顶部