没有合适的资源?快使用搜索试试~ 我知道了~
WinDriver 的PCI开发手册
需积分: 19 33 下载量 126 浏览量
2018-06-04
21:18:55
上传
评论 1
收藏 2.12MB PDF 举报
温馨提示
试读
338页
最新版的使用windriver开发PCI的手册,Version 12.7,详细介绍了PCI开发的过程。
资源推荐
资源详情
资源评论
WinDriver™ PCI/ISA User's
Manual
Jungo Connectivity Ltd.
Version 12.7.0
© 2018 Jungo Connectivity Ltd. ii CONFIDENTIAL
WinDriver™ PCI/ISA User's Manual
Copyright © 2018 Jungo Connectivity Ltd. All Rights Reserved
Information in this document is subject to change without notice. The software described in this document is furnished under a license
agreement. The software may be used, copied or distributed only in accordance with that agreement. No part of this publication
may be reproduced, stored in a retrieval system, or transmitted in any form or any means, electronically or mechanically, including
photocopying and recording for any purpose without the written permission of Jungo Connectivity Ltd.
Brand and product names mentioned in this document are trademarks of their respective owners and are used here only for
identification purposes.
© 2018 Jungo Connectivity Ltd. iii CONFIDENTIAL
Table of Contents
1. WinDriver Overview .................................................................................................................. 1
1.1. Introduction to WinDriver ............................................................................................... 1
1.2. Background ...................................................................................................................... 2
1.2.1. The Challenge ....................................................................................................... 2
1.2.2. The WinDriver Solution ....................................................................................... 2
1.3. How Fast Can WinDriver Go? ........................................................................................ 3
1.4. Conclusion ....................................................................................................................... 3
1.5. WinDriver Benefits .......................................................................................................... 3
1.6. WinDriver Architecture ................................................................................................... 5
1.7. What Platforms Does WinDriver Support? ..................................................................... 6
1.8. Limitations of the Different Evaluation Versions ........................................................... 6
1.9. How Do I Develop My Driver with WinDriver? ............................................................ 7
1.9.1. On Windows and Linux ....................................................................................... 7
1.10. What Does the WinDriver Toolkit Include? ................................................................. 7
1.10.1. WinDriver Modules ............................................................................................ 7
1.10.2. Utilities ................................................................................................................ 8
1.10.3. Samples and Enhanced-Support Chipset APIs ................................................... 9
1.10.3.1. Enhanced Chipset Support ....................................................................... 9
1.11. Can I Distribute the Driver Created with WinDriver? .................................................. 9
2. Understanding Device Drivers ................................................................................................. 10
2.1. Device Driver Overview ................................................................................................ 10
2.2. Classification of Drivers According to Functionality ................................................... 10
2.2.1. Monolithic Drivers .............................................................................................. 10
2.2.2. Layered Drivers .................................................................................................. 11
2.2.3. Miniport Drivers ................................................................................................. 12
2.3. Classification of Drivers According to Operating Systems .......................................... 13
2.3.1. WDM Drivers ..................................................................................................... 13
2.3.2. Unix Device Drivers ........................................................................................... 14
2.3.3. Linux Device Drivers ......................................................................................... 14
2.4. The Entry Point of the Driver ....................................................................................... 14
2.5. Associating the Hardware with the Driver .................................................................... 15
2.6. Communicating with Drivers ........................................................................................ 15
3. Installing WinDriver ................................................................................................................. 16
3.1. System Requirements .................................................................................................... 16
3.1.1. Windows System Requirements ......................................................................... 16
3.1.2. Linux System Requirements ............................................................................... 17
3.2. WinDriver Installation Process ...................................................................................... 17
3.2.1. Windows WinDriver Installation Instructions .................................................... 17
3.2.2. Linux WinDriver Installation Instructions .......................................................... 18
3.2.2.1. Preparing the System for Installation ...................................................... 18
3.2.2.2. Installation ................................................................................................ 19
3.2.2.3. Restricting Hardware Access on Linux ................................................... 21
3.3. Upgrading Your Installation .......................................................................................... 21
3.4. Checking Your Installation ............................................................................................ 22
3.4.1. Windows and Linux Installation Check ............................................................. 22
3.5. Uninstalling WinDriver ................................................................................................. 22
Table of Contents
© 2018 Jungo Connectivity Ltd. iv CONFIDENTIAL
3.5.1. Windows WinDriver Uninstall Instructions ....................................................... 23
3.5.2. Linux WinDriver Uninstall Instructions ............................................................. 25
4. Using DriverWizard .................................................................................................................. 26
4.1. An Overview .................................................................................................................. 26
4.2. DriverWizard Walkthrough ........................................................................................... 27
4.2.1. Automatic Code Generation ............................................................................... 34
4.2.1.1. Generating the Code ................................................................................ 34
4.2.1.2. The Generated PCI/ISA C Code ............................................................. 34
4.2.2. Compiling the Generated Code .......................................................................... 35
4.2.2.1. Windows Compilation ............................................................................. 35
4.2.2.2. Linux Compilation ................................................................................... 36
5. Developing a Driver ................................................................................................................. 37
5.1. Using DriverWizard to Build a Device Driver ............................................................. 37
5.2. Writing the Device Driver Without DriverWizard ........................................................ 38
5.2.1. Include the Required WinDriver Files ............................................................... 38
5.2.2. Write Your Code ................................................................................................ 39
5.2.3. Configure and Build Your Code ........................................................................ 39
6. Debugging Drivers .................................................................................................................... 41
6.1. User-Mode Debugging .................................................................................................. 41
6.2. Debug Monitor ............................................................................................................... 41
6.2.1. The wddebug_gui Utility .................................................................................... 42
6.2.1.1. Search in wddebug_gui ........................................................................... 45
6.2.1.2. Opening Windows kernel crash dump with wddebug_gui ...................... 46
6.2.1.3. Running wddebug_gui for a Renamed Driver ......................................... 46
6.2.2. The wddebug Utility ........................................................................................... 46
6.2.2.1. Console-Mode wddebug Execution ......................................................... 46
7. Enhanced Support for Specific Chipsets .................................................................................. 50
7.1. Overview ........................................................................................................................ 50
7.2. Developing a Driver Using the Enhanced Chipset Support .......................................... 50
8. PCI Express .............................................................................................................................. 52
8.1. PCI Express Overview .................................................................................................. 52
8.2. WinDriver for PCI Express ........................................................................................... 53
9. Advanced Issues ....................................................................................................................... 54
9.1. Performing Direct Memory Access (DMA) .................................................................. 54
9.1.1. Implementing Scatter/Gather DMA .................................................................... 55
9.1.2. Implementing Contiguous-Buffer DMA ........................................................... 57
9.1.2.1. Preallocating Contiguous DMA Buffers on Windows ............................ 59
9.2. Handling Interrupts ........................................................................................................ 62
9.2.1. Interrupt Handling — Overview ........................................................................ 62
9.2.2. WinDriver Interrupt Handling Sequence ............................................................ 64
9.2.3. Registering IRQs for Non-Plug-and-Play Hardware on Windows 7 and
Higher ............................................................................................................................ 65
9.2.4. Determining the Interrupt Types Supported by the Hardware ........................... 66
9.2.5. Determining the Interrupt Type Enabled for a PCI Card ................................... 67
9.2.6. Setting Up Kernel-Mode Interrupt Transfer Commands .................................... 67
9.2.6.1. Interrupt Mask Commands ...................................................................... 68
9.2.6.2. Sample WinDriver Transfer Commands Code ........................................ 68
9.2.7. WinDriver MSI/MSI-X Interrupt Handling ........................................................ 69
Table of Contents
© 2018 Jungo Connectivity Ltd. v CONFIDENTIAL
9.2.7.1. Windows MSI/MSI-X Device INF Files ................................................. 70
9.2.8. Sample User-Mode WinDriver Interrupt Handling Code ................................... 71
9.3. Buffer sharing between multiple processes ................................................................... 74
10. Improving Performance .......................................................................................................... 75
10.1. Overview ...................................................................................................................... 75
10.1.1. Performance Improvement Checklist ............................................................... 76
10.2. Improving the Performance of a User-Mode Driver ................................................... 77
10.2.1. Using Direct Access to Memory-Mapped Regions .......................................... 77
10.2.2. Block Transfers and Grouping Multiple Transfers ........................................... 78
10.2.3. Performing 64-Bit Data Transfers .................................................................... 78
11. Understanding the Kernel PlugIn ........................................................................................... 80
11.1. Background .................................................................................................................. 80
11.2. Do I Need to Write a Kernel PlugIn Driver? .............................................................. 80
11.3. What Kind of Performance Can I Expect? ................................................................. 81
11.4. Overview of the Development Process ....................................................................... 81
11.5. The Kernel PlugIn Architecture .................................................................................. 81
11.5.1. Architecture Overview ...................................................................................... 81
11.5.2. WinDriver's Kernel and Kernel PlugIn Interaction .......................................... 82
11.5.3. Kernel PlugIn Components .............................................................................. 83
11.5.4. Kernel PlugIn Event Sequence ......................................................................... 83
11.5.4.1. Opening a Handle from the User Mode to a Kernel PlugIn Driver ........ 83
11.5.4.2. Handling User-Mode Requests from the Kernel PlugIn ........................ 84
11.5.4.3. Interrupt Handling — Enable/Disable and
High Interrupt Request Level Processing .............................................................. 85
11.5.4.4. Interrupt Handling — Deferred Procedure Calls ................................... 86
11.5.4.5. Plug-and-Play and Power Management Events ..................................... 87
11.6. How Does Kernel PlugIn Work? ................................................................................ 87
11.6.1. Minimal Requirements for Creating a Kernel PlugIn Driver ........................... 87
11.6.2. Kernel PlugIn Implementation ......................................................................... 88
11.6.2.1. Before You Begin .................................................................................. 88
11.6.2.2. Write Your KP_Init Function ................................................................ 88
11.6.2.3. Write Your KP_Open Function(s) ......................................................... 90
11.6.2.4. Write the Remaining PlugIn Callbacks ................................................. 95
11.6.3. Sample/Generated Kernel PlugIn Driver Code Overview ................................ 95
11.6.4. Kernel PlugIn Sample/Generated Code Directory Structure ............................ 96
11.6.4.1. pci_diag and kp_pci Sample Directories ............................................... 96
11.6.4.2. The Generated DriverWizard Kernel PlugIn Directory ......................... 98
11.6.5. Handling Interrupts in the Kernel PlugIn ....................................................... 100
11.6.5.1. Interrupt Handling in the User Mode (Without the Kernel PlugIn) ..... 100
11.6.5.2. Interrupt Handling in the Kernel (Using the Kernel PlugIn) ............... 101
11.6.6. Message Passing ............................................................................................. 103
12. Creating a Kernel PlugIn Driver .......................................................................................... 105
12.1. Determine Whether a Kernel PlugIn is Needed ........................................................ 105
12.2. Prepare the User-Mode Source Code ........................................................................ 105
12.3. Create a New Kernel PlugIn Project ......................................................................... 106
12.4. Open a Handle to the Kernel PlugIn ......................................................................... 107
12.5. Set Interrupt Handling in the Kernel PlugIn ............................................................. 108
12.6. Set I/O Handling in the Kernel PlugIn ...................................................................... 109
剩余337页未读,继续阅读
资源评论
PrintHope
- 粉丝: 0
- 资源: 2
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 基于springboot+vue实现的在线考试系统+源代码+文档
- RTL8723DS 2022 版本 Linux驱动,android驱动 支持4.0-10x
- 要玩NDS的遊戲,必須要先下載三個bios檔案到你的檔案資料夾
- 各类型数据库4月排名,基于排名网站数据爬虫json结果
- 基于springboot+vue实现的在线考试系统+源代码+文档
- 淮北市杜集区人才补贴+生活补贴
- JAVA-JSP技术文档
- 课内实验02-决策表(共享单车月卡).docx
- 基于【React + Node+SpringBoot】疫情数据查看系统的设计与实现【源码+lw+部署+讲解】
- 基于【React + Node】云课堂系统设计与实现【源码+lw+部署+讲解】
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功