PUBLISHED BY Microsoft Press
A Division of Microsoft Corporation
One Microsoft Way Redmond, Washington 98052-6399
Copyright © 2007 by Microsoft Corporation9780735623743
All rights reserved. No part of the contents of this book may be reproduced or transmitted in any form or by any means without the written permission of the publisher.
Library of Congress Control Number: 2007922586
Printed and bound in the United States of America.
1 2 3 4 5 6 7 8 9 QWT 2 1 0 9 8 7
Distributed in Canada by H.B. Fenn and Company Ltd.
A CIP catalogue record for this book is available from the British Library.
Microsoft Press books are available through booksellers and distributors worldwide. For further information about international editions, contact your local Microsoft Corporation office or contact Microsoft Press International directly at fax (425) 936–7329. Visit our Web site at www.microsoft.com/mspress. Send comments to firstname.lastname@example.org.
Microsoft, Microsoft Press, Excel, Internet Explorer, MSDN, MS-DOS, Outlook, SideShow, Visual Studio, Win32, Windows, Windows Media, Windows NT, Windows Server, Windows Vista, Xbox, and Xbox 360 are either registered trademarks or trademarks of Microsoft Corporation in the United States and/or other countries. Other product and company names mentioned herein may be the trademarks of their respective owners.
The example companies, organizations, products, domain names, e-mail addresses, logos, people, places, and events depicted herein are fictitious. No association with any real company, organization, product, domain name, e-mail address, logo, person, place, or event is intended or should be inferred.
This book expresses the author's views and opinions. The information contained in this book is provided without any express, statutory, or implied warranties. Neither the authors, Microsoft Corporation, nor its resellers, or distributors will be held liable for any damages caused or alleged to be caused either directly or indirectly by this book.
Acquisitions Editor: Ben Ryan
Developmental Editor: Devon Musgrave
Project Editor: Denise Bankaitis
Body Part No. X13-62472
Penny Orwick is an independent writer working with Steyer Associates, specializing in driver development and Windows operating system topics. She began writing about Windows drivers in 1997 and has worked with the Windows Driver Foundation team from the outset of the project to develop technical papers about WDF for the driver development community. Penny has a B.A. from Cornell University and an M.F.A. from the University of Montana.
Guy Smith started programming in Fortran IV on punch cards as a Geophysics graduate student. He began writing SDK documentation for Microsoft early in 1996 and has since worked on many Microsoft technologies including Windows CE, the Windows Shell and Common Controls, DirectX 8, Internet Explorer, and the Windows Presentation Foundation. He now works as an independent writer with Steyer Associates, focusing on device drivers and related kernel-mode topics. Guy is a dedicated amateur early musician, performing the music of the Renaissance on lute, cittern, and serpent.
Carol Buchmiller has been writing and editing documentation for personal computer software since 1981. After working at Microsoft in the early 1980s, Carol has written for various software companies in the Pacific Northwest, eventually specializing in Windows kernel-mode drivers and hardware compatibility topics. In 2000, Carol joined Microsoft to write for the Windows Hardware Developer Central Web site. Carol has a B.A. from Whitman College and has completed certificate programs in C and C++.
Annie Pearson began writing and editing software documentation in 1982. She began writing and managing technical documentation projects for Windows with the Windows 3.1 Resource Kit. Annie has been the lead writer and information architect for the Windows Hardware Developer Central Web site since 1997.
The authors acknowledge with deep gratitude the extraordinary contributions made by members of the Windows Driver Foundation team at Microsoft in providing technical information, code samples, reviews, and encouragement. Doron Holan, Narayanan Ganapathy, Praveen Rao, Eliyas Yakub, and Peter Wieland were instrumental in creating and shaping this book, which also relied on key contributions from John Richardson in creating early drafts. Donn Terry and Vlad Levin provided key guidance in developing the PREfast for Drivers and Static Driver Verifier chapters, respectively.
We salute the leadership and early development contributions to the Windows Driver Foundation by the architect on the project, Narayanan Ganapathy. Other visionary individuals who provided early support for the project were Brad Carpenter, Vince Orgovan, Bob Rinne, Rob Short, and Mike Tricker.
Johan Marien, program manager during the development phase for WDF, launched the ongoing effort to discuss driver model directions with the Windows driver developer community. We want to acknowledge the significant contributions from Peter Viscarola and Open Systems Resources, Inc. (OSR), especially for their fervent evangelism and their work on the OSR USB Fx2 Learning Kit, upon which several of the WDF samples are based. Valuable review comments and great ideas were also contributed by several of the driver development community's "Most Valued Professionals" and leading Windows driver developers: Don Burn, Trevor Goveas (Agere), Bill McKenzie, Tim Roberts (Providenza & Boekelheide), Mark Roddy (Hollis Technology Solutions), Eric Tissot-Dupont (Logitech), and Ray Trent (Synaptics).
A project as extensive as WDF would not be possible without the dedicated product development teams working to turn a vision into a product.
WDF would not exist without the extraordinarily talented design and development team. Significant contributors were Robin Callendar, Joe Dai, Doron Holan, Vishal Manan, Adrian Oney, Jake Oshins, Ray Patrick, Guruprakash Rao, Abhishek Ram, Praveen Rao, John Richardson, Mukund Sankaranarayan, Erick Smith, Peter Wieland, and Eliyas Yakub.
Static analysis and verification tools are a key part of WDF. Tom Ball and Sriram Rajamani invented the SLAM verification engine and, supported by the WDF group, made a successful presentation to Bill Gates on a state-of-art driver verification technology based on SLAM. These events led to a launch of the Static Driver Verifier project in the WDF group. Further important contributions to the static tools were made by Vlad Levin, Donn Terry, Ella Bounimova, Byron Cook, Jakob Lichtenberg, and Con McGarvey.
The WDF test team ensured the quality of the frameworks. The leaders for test development were Quetzel Bradley for WDF and Static Tools, Ravi Gollapudi for KMDF, and Abdullah Ustuner for UMDF and Static Tools. KMDF Test contributors were Aruna Banda, Bob Kjelgaard, Kumar Rajeev, and Willem van der Hoeven. UMDF test contributors were Shefali Gulati, Shyamal Varma, Jimmy Chen, Patrick Maninger, and James Moe. Static Tools test contributors were Jon Hagen, Onur Ozyer, and John Henry.
Documentation is critical for all products and especially for developer tools. Richard Brown, Dave Hagen, John Jackson, and Adam Wilson contributed to the WDF documentation.
We appreciate Microsoft management for believing and investing in the WDF project and the program managers for helping to identify and remove road blocks to bring the Windows Driver Foundation to the driver community. The managers on the project were Fran Dougherty, Stu Farnham, and Harish Naidu. The program managers on the project were Johan Marien, Jeffrey Copeland, Murtuza Naguthanawala, Bohus Ondrusek, and Teresa Stone.
Many Microsoft teams contributed to the WDF initiative by becoming early adopters of WDF and providing feedback to the development team:
Microsoft Hardware: Vadim Dmitriev
Tablet PC: Mikki Durojaiye
Windows Client Technologies for Emerging Markets: Zhangwei Xu
Windows I/O Manager: John Lee, Paul Sliwowicz
Windows Media Player/Windows Portable Devices: Oren Rosenbloom, Vlad Sadovsky, Byron Changuion, Cooper Partin, E-Zu Wu, Jim Bovee, John Felkins, Blake Manders
Windows SideShow: Dan Polivy
Windows Universal Audio Architecture - High Definition Audio: Hakon Strande, Frank Berreth, Cheng-mean Liu
Windows Virtualization: Jake Oshins, Benjamin Leis
WinUSB: Randy Aull
Xbox 360 Controller: Matt Coill
- from the authors, Developing Drivers with the Microsoft Windows Driver Foundation: Penny Orwick, Guy Smith, Carol Buchmiller, Annie Pearson, Gwen Heib, and the Windows Hardware Developer Central (WHDC) team at Microsoft.