阅读:836回复:1
我是新手,有些低级问题请教各位高手!!!!
1。IO请求的地址和字节等参数是通过什么传给驱动程序的呀?
2。中断程序怎么区分不同的中断源呢? 3。Packet-base System DMA和Common Buffer System DMA的 区别是什么呢? 问题比较低级,请朋友帮助!! 谢谢! |
|
沙发#
发布于: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. |
|
|