How we did it:
Ole Henry Halvorsen, Douglas Clarke
OS X and iOS Kernel Programming combines essential operating system and kernel architecture knowledge with a highly practical approach that will help you write effective kernel-level code. You’ll learn fundamental concepts such as memory management and thread synchronization, as well as the I/O Kit framework. You’ll also learn how to write your own kernel-level extensions, such as device drivers for USB and Thunderbolt devices, including networking, storage and audio drivers. OS X and iOS Kernel Programming provides an incisive and complete introduction to the XNU kernel, which runs iPhones, iPads, iPods, and Mac OS X servers and clients. Then, you’ll expand your horizons to examine Mac OS X and iOS system architecture. Understanding Apple’s operating systems will allow you to write efficient device drivers, such as those covered in the book, using I/O Kit. With OS X and iOS Kernel Programming, you’ll: Discover classical kernel architecture topics such as memory management and thread synchronization Become well-versed in the intricacies of the kernel development process by applying kernel debugging and profiling tools Learn how to deploy your kernel-level projects and how to successfully package them Write code that interacts with hardware devices Examine easy to understand example code that can also be used in your own projects Create network filters Whether you’re a hobbyist, student, or professional engineer, turn to OS X andiOS Kernel Programming and find the knowledge you need to start developing What you’ll learn OS X and iOS common core architecture How to write extremely efficient code by exploiting kernel details Coding kernel-level extensions How to write device drivers How to program the I/O Kit framework Key mobile device topics like power management drivers and video capture modules To understand OS X memory management and threads To parse kernel debug messages and package projects ready for deployment Who this book is for This book is suited for: Intermediate and advanced iPhone and OS X programmers ready for the next step Kernel-level programmers interested in how OS X and iOS function Open source programmers with a background in Linux or BSD, OS X and iOS Programmers interested in application performance System administrators running OS X clusters Table of Contents Operating System Fundamentals Mac OS X and iOS Xcode and the Kernel Development Environment The I/O Kit Framework Interacting with Drivers from Applications Memory Management Synchronisation and Threading USB Drivers PCI and Thunderbolt Power Management Serial Port Drivers Core Audio Network Drivers Storage Drivers and Filesystems User-Space Drivers Debugging and Profiling Advanced Kernel Programming Deployment
The Microsoft® Windows® driver model (WDM) supports Plug and Play, provides power management capabilities, and expands on the driver/minidriver approach. Written by long-time device-driver expert Walter Oney in cooperation with the Windows kernel team, this book provides extensive practical examples, illustrations, advice, and line-by-line analysis of code samples to clarify real-world driver-programming issues. And it's been updated with the latest details about the driver technologies in Windows XP and Windows 2000, plus more information about how to debug drivers. Topics covered include: Beginning a driver project and the structure of a WDM driver; NEW: Minidrivers and class drivers, driver taxonomy, the WDM development environment and tools, management checklist, driver selection and loading, approved API calls, and driver stacks Basic programming techniques; NEW: Safe string functions, memory limits, the Driver Verifier scheme and tags, the kernel handle flag, and the Windows 98 floating-point problem Synchronization; NEW: Details about the interrupt request level (IRQL) scheme, along with Windows 98 and Windows Me compatibility The I/O request packet (IRP) and I/O control operations; NEW: How to send control operations to other drivers, custom queue implementations, and how to handle and safely cancel IRPs Plug and Play for function drivers; NEW: Controller and multifunction devices, monitoring device removal in user mode, Human Interface Devices (HID), including joysticks and other game controllers, minidrivers for non-HID devices, and feature reports Reading and writing data, power management, and Windows Management Instrumentation (WMI) NEW: System wakeup, the WMI control for idle detection, and using WMIMOFCK Specialized topics and distributing drivers; NEW: USB 2.0, selective suspend, Windows Hardware Quality Lab (WHQL) certification, driver selection and loading, officially approved API calls, and driver stacks COVERS WINDOWS 98, WINDOWS ME, WINDOWS 2000, AND WINDOWS XP! CD-ROM FEATURES: A fully searchable electronic copy of the book Sample code in Microsoft Visual C++® A Note Regarding the CD or DVD The print version of this book ships with a CD or DVD. For those customers purchasing one of the digital formats in which this book is available, we are pleased to offer the CD/DVD content as a free download via O'Reilly Media's Digital Distribution services. To download this content, please visit O'Reilly's web site, search for the title of this book to find its catalog page, and click on the link below the cover image (Examples, Companion Content, or Practice Files). Note that while we provide as much of the media content as we are able via free download, we are sometimes limited by licensing restrictions. Please direct any questions or concerns to email@example.com.
Teach your students to design, develop, and validate USB systems with ease, using this valuable resource that provides a detailed bootstrap session on the Linux-USB design and implementation. BOOTSTRAP YOURSELF WITH LINUX-USB STACK: DESIGN, DEVELOP, DEBUG, AND VALIDATE EMBEDDED USB SYSTEMS offers an in-depth tour of the Linux USB stack, clearly and meticulously explaining how to develop drivers for USB device and host controllers on Linux. It moves on to explore the interfaces and data structures of USB module with UML diagrams, concluding each chapter with a sample implementation that applies the information just covered. A comprehensive look at the various tools and methods available on Linux to validate a USB system is also provided. Using a clear, straightforward writing style, this will be a powerful tool for students as they learn to develop a protocol stack with proper architecture and design, ultimately leading to better quality, maintainability, and testability.