Programming Books C Java PHP Python Learn more Browse Programming Books
Essential Linux Device Drivers and over one million other books are available for Amazon Kindle. Learn more

Sorry, this item is not available in
Image not available for
Image not available

To view this video download Flash Player


Sign in to turn on 1-Click ordering
Sell Us Your Item
For a $12.26 Gift Card
Trade in
More Buying Choices
Have one to sell? Sell yours here
Start reading Essential Linux Device Drivers on your Kindle in under a minute.

Don't have a Kindle? Get your Kindle here, or download a FREE Kindle Reading App.

Essential Linux Device Drivers [Hardcover]

Sreekrishnan Venkateswaran
4.2 out of 5 stars  See all reviews (24 customer reviews)

List Price: $54.99
Price: $38.44 & FREE Shipping. Details
You Save: $16.55 (30%)
o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o
Only 12 left in stock (more on the way).
Ships from and sold by Gift-wrap available.
Want it Friday, July 11? Choose One-Day Shipping at checkout. Details
Free Two-Day Shipping for College Students with Amazon Student


Amazon Price New from Used from
Kindle Edition $22.99  
Hardcover $38.44  
Paperback --  
Books for Pragmatic Programmers
Find resources for various programming needs, including agile teams, programming languages, and the life of a programmer, in the Pragmatic Bookshelf.

Book Description

April 6, 2008 0132396556 978-0132396554 1

“Probably the most wide ranging and complete Linux device driver book I’ve read.”

--Alan Cox, Linux Guru and Key Kernel Developer


“Very comprehensive and detailed, covering almost every single Linux device driver type.”

--Theodore Ts’o, First Linux Kernel Developer in North America and Chief Platform Strategist of the Linux Foundation


The Most Practical Guide to Writing Linux Device Drivers

Linux now offers an exceptionally robust environment for driver development: with today’s kernels, what once required years of development time can be accomplished in days. In this practical, example-driven book, one of the world’s most experienced Linux driver developers systematically demonstrates how to develop reliable Linux drivers for virtually any device. Essential Linux Device Drivers is for any programmer with a working knowledge of operating systems and C, including programmers who have never written drivers before. Sreekrishnan Venkateswaran focuses on the essentials, bringing together all the concepts and techniques you need, while avoiding topics that only matter in highly specialized situations. Venkateswaran begins by reviewing the Linux 2.6 kernel capabilities that are most relevant to driver developers. He introduces simple device classes; then turns to serial buses such as I2C and SPI; external buses such as PCMCIA, PCI, and USB; video, audio, block, network, and wireless device drivers; user-space drivers; and drivers for embedded Linux–one of today’s fastest growing areas of Linux development. For each, Venkateswaran explains the technology, inspects relevant kernel source files, and walks through developing a complete example.


• Addresses drivers discussed in no other book, including drivers for I2C, video, sound, PCMCIA, and different types of flash memory

• Demystifies essential kernel services and facilities, including kernel threads and helper interfaces

• Teaches polling, asynchronous notification, and I/O control

• Introduces the Inter-Integrated Circuit Protocol for embedded Linux drivers

• Covers multimedia device drivers using the Linux-Video subsystem and Linux-Audio framework

• Shows how Linux implements support for wireless technologies such as Bluetooth, Infrared, WiFi, and cellular networking

• Describes the entire driver development lifecycle, through debugging and maintenance

• Includes reference appendixes covering Linux assembly, BIOS calls, and Seq files

Frequently Bought Together

Essential Linux Device Drivers + Linux Device Drivers, 3rd Edition + Linux Kernel Development (3rd Edition)
Price for all three: $101.09

Buy the selected items together

Editorial Reviews

About the Author

Sreekrishnan Venkateswaran has spent more than a decade working in IBM product development laboratories. He has ported Linux to devices ranging from wristwatches and music players to PDAs, VoIP phones, and even pacemaker programmers. He was a Contributing Editor and kernel columnist for Linux Magazine for more than two years.

Excerpt. © Reprinted by permission. All rights reserved.


Essential Linux Device Drivers

by Sreekrishnan Venkiteswaran


It was the late nineties and at IBM, we were putting the Linux kernel on a wrist watch. The target device was tiny, but the task was turning out to be tough. The Memory Technology Devices subsystem didn't exist in the kernel, which meant that before a filesystem could start life on the watch's flash memory, we had to develop the necessary storage driver from scratch. Interfacing the watch's touch screen with user applications was complicated since the kernel's input event driver interface hadn't been conceived yet. Getting X-Windows to run on the watch's LCD wasn't easy since it didn't work well with framebuffer drivers. Of what use is a water-proof Linux wrist watch if you can't stream stock quotes from your bath tub? Bluetooth integration with Linux was several years away, and months were spent porting a proprietary Bluetooth stack to Internet-enable the watch. Power management support was good enough only to squeeze a few hours of juice from the watch's battery, hence we had work cut out on that front too. Linux-Infrared was still unstable, so we had to coax the stack before we could use an Infrared keyboard for data entry. And we had to compile the compiler and cross-compile a compact application-set since there were no accepted distributions in the consumer electronics space.

Fast forward to the present: The baby penguin has grown into a healthy teenager. What took thousands of lines of code and a year in development back then, can be accomplished in a few days with the current kernels. But to become a versatile kernel engineer who can magically weave solutions, you need to understand the myriad features and facilities that Linux offers today.

About the Book

Among the various subsystems residing in the kernel source tree, the drivers/ directory constitutes the single largest chunk and is several times bigger than the others. With new and diverse technologies arriving in popular form factors, the development of new device drivers in the kernel is accelerating steadily. The latest kernels support over 50 device driver families.

This book is about writing Linux device drivers. It covers the design and development of major device classes supported by the kernel, including those I missed during my Linux-on-Watch days. The discussion of each driver family starts by looking at the corresponding technology, moves on to develop a practical example, and ends by looking at relevant kernel source files. But before foraying into the world of device drivers, the book introduces you to the kernel and discusses the important features of 2.6 Linux, emphasizing those portions that are of special interest to device driver writers.


This book is intended for the intermediate-level programmer eager to tweak the kernel to enable new devices. You should have a working knowledge of operating system concepts. For example, you should know what a system call is, and why concurrency issues have to be factored in while writing kernel code. The book assumes that you have downloaded Linux on your system, poked through the kernel sources, and at least skimmed through some related documentation. And you should be pretty good in C.

Summary of Chapters

The first three chapters prepare you to digest the rest of the book. Each of the next fifteen chapters discusses drivers for a specific device family. The following chapter is a hold-all for driver classes not covered thus far. The penultimate chapter discusses device driver debugging. The last chapter gives some perspective on delivery and maintenance.

Chapter 1, "Introduction," starts our tryst with Linux. It hurries you through downloading the kernel sources, making trivial code changes, and building a bootable kernel image.

Chapter 2, "A Peek Inside the Kernel," takes a brisk peek into the innards of the Linux kernel and teaches you some must-know kernel concepts. It first takes you through the boot process and then describes kernel services particularly relevant to driver development such as kernel threads, timers, concurrency, and memory management.

Chapter 3, "Getting Started with Device Drivers," gets you started with the art of writing Linux device drivers. It looks at interrupt handling, the new Linux device model, and Linux assembly. In this chapter, you'll also learn to use kernel helper interfaces such as linked lists, work queues, completion functions, and notifier chains. These helper facilities simplify your code, weed out redundancies from the kernel, and help long-term maintenance.

Chapter 4, "Character Drivers," looks at the architecture of character device drivers. Several concepts introduced in this chapter such as polling, asynchronous notification, and I/O control, are relevant to subsequent chapters as well, since many device classes discussed in the rest of the book are 'super' character devices.

Chapter 5, "Serial Drivers," explains the kernel layer that handles serial devices. The serial layer consists of low-level drivers, the TTY layer, and line disciplines.

Chapter 6, "Input Drivers," discusses the kernel's input subsystem that is responsible for servicing devices such as keyboards, mice, and touch panels.

Chapter 7, "The Inter-Integrated Circuit Protocol," dissects drivers for devices such as EEPROMs that are connected to the system I2C bus or SMBus. The chapter also looks at other serial technologies such as the SPI bus and one-wire bus.

Chapter 8,"PCMCIA and Compact Flash," delves into the PCMCIA subsystem. It teaches you to write drivers for devices having a PCMCIA or Compact Flash form factor.

Chapter 9, "Peripheral Component Interconnect," looks at kernel support for PCI and its derivatives such as CardBus and PCI Express.

Chapter 10, "Universal Serial Bus," explores USB architecture and device drivers.

Chapter 11, "Video Drivers," explains the Linux video family.

Chapter 12, "Audio Drivers," describes the Linux audio family.

Chapter 13, "Block Drivers," covers drivers for devices such as IDE and SCSI. It also looks at filesystem drivers.

Chapter 14, "Network Interface Cards," is dedicated to network devices. You'll learn about kernel networking data structures and how to interface network drivers with protocol layers.

Chapter 15, "Linux Without Wires," looks at driving different wireless technologies such as Bluetooth, Infrared, WiFi and cellular communication.

Chapter 16, "Memory Technology Devices," discusses flash memory enablement. This chapter first looks at flash-based protocols and chipsets primarily used on embedded devices. It ends by examining drivers for the Firmware Hub found on desktops and laptops.

Chapter 17, "Embedding Linux," steps into the world of embedded Linux. It takes you through the main firmware components of an embedded solution, such as bootloader, kernel, and device drivers. Given the soaring popularity of Linux in the embedded space, it's likely that you'll use the device driver skills that you acquire from this book, to enable embedded devices.

Chapter 18, "User Mode Drivers," looks at driving different types of devices from user space. Some device drivers, especially ones that are heavy on policy and light on performance requirements, are better off residing in user land. This chapter also explains how the new ultra-scalable process scheduler improves response times of user mode drivers.

Chapter 19, "More Devices and Drivers," takes a tour of a potpourri of driver families not covered thus far, such as Error Detection And Correction (EDAC), cpufreq<...

Product Details

  • Hardcover: 744 pages
  • Publisher: Prentice Hall; 1 edition (April 6, 2008)
  • Language: English
  • ISBN-10: 0132396556
  • ISBN-13: 978-0132396554
  • Product Dimensions: 9.3 x 7.3 x 1.6 inches
  • Shipping Weight: 2.7 pounds (View shipping rates and policies)
  • Average Customer Review: 4.2 out of 5 stars  See all reviews (24 customer reviews)
  • Amazon Best Sellers Rank: #342,559 in Books (See Top 100 in Books)

More About the Author

Discover books, learn about writers, read author blogs, and more.

Customer Reviews

Most Helpful Customer Reviews
31 of 35 people found the following review helpful
3.0 out of 5 stars Can't replace the O'Reilly text January 28, 2009
Like other reviews have stated, this first half of this book is a concise, useful introduction to certain Linux kernel concepts. But the title of the book leads the reader to expect that they could produce a Linux device driver using this book. That turns out not to be the case - no one could produce a driver with this book without the benefit of other reference material. In short, while the O'Reilly "Linux Device Drivers" text has it's shortcomings and is starting to become dated, it is still the only text with which the reader can use as a primary reference to create their own driver. It discusses implementation in detail, which this book does not.

This brings me to the second half of "Essential Linux Device Drivers", where specific device types are discussed. So little time is spent on each type that none are covered in enough detail to actually go off and start a driver of that type. You could be thinking that this book never claimed to enable you to write a PCI driver, for example, and that would be true. It just feels like a reduced scope with increased depth on the remainder would have made a much more useful book, rather than a bathroom reader.
Comment | 
Was this review helpful to you?
28 of 35 people found the following review helpful
2.0 out of 5 stars Get Linux Device Drivers from O'REILLY instead February 10, 2009
Format:Hardcover|Verified Purchase
The people who gave this book 5 starts are either friends of the author, the author himself, or guys who have been writing linux drivers for years and felt like reading what they already knew. Although the author seems to be very knowledgeable on the topic, his book is really terrible at explaining the essential kernel functions needed for writing device drivers and their respective parameters. He only mentions that they exist. To understand what the author is doing, you would have to resort to searching alternate references. Also his examples don't work. I can tell that he never tried to compiled these examples.

After reading the first few chapters, I decided to get the linux device drivers book from O'REILLY and as soon as I started reading, I could point out loads of important information that the first book failed to relay. The examples in the O'REILLY book are also by far better.
Comment | 
Was this review helpful to you?
7 of 7 people found the following review helpful
Anyone who is looking to purchase this book is either taking a class in driver development or is new to driver development and is looking for guidance. This book is a great attempt at an all in one driver development book, however; falls flat due to errors in the text and code samples. Sadly it is obvious there was very little error checking or testing of code samples in the book. Someone who is new to such a complex subject should be able to rely on accurate code example and explanations without having to constantly be on the lookout for errors. Some of the errors found are expected of new CS students and not seasoned professionals ( eg. Performing kmalloc() without calling kfree() ) or (allocating memory to a single variable in a for loop eg. var_ptr = kmalloc() both of which exist in Example 5.1 of the book ). The author also fails to explain kernel function's arguments and only mentioned the kernel functions themselves. This makes it difficult to know what/why arguments are being passed.

Please see the author's errata page:

[...](Link removed by Amazon)

Additionally there is another errata page for the book:

[...](Link removed by Amazon)

The high number of errors take away from the readers experience with learning the subject. More time is spent reading and checking the author's Errata page to make sure they are not misinformed. This book will probably be worth 4 stars if they release a second edition with all the errors fixed. It may be worth picking up LDD3 as a supplement and probably has less errors. Additionally, the author spends a ton of time in the beginning discussing kernel threads, klists, ktrees, IRQs, softirqs, and other key kernel components and hardware specifics.
Read more ›
Was this review helpful to you?
18 of 22 people found the following review helpful
5.0 out of 5 stars Best Linux device driver book yet May 6, 2008
I've been frustrated by many other Linux kernel and device driver books. The authors often make assumptions about the readers knowledge and gloss over areas that can be quite confusing.

To some extent, that's unavoidable: the Linux kernel is monstrous and very complex, and the hardware that drivers control can also be dark and mysterious territory.

I really appreciated this books approach. It's not that everything is explained in complete detail; that would be impossible. However, the author obviously tries very hard to give an overview, an orientation that will hopefully set your mind in the right direction, before diving into details. Throughout the book he adds "go look at this" suggestions that can help you understand whatever he's dealing with at this point.

I think Chapter 2, which is a high level fly-by of the kernel in general, is an absolute masterpiece. That starts by pulling typical kernel boot messages and explaining what they mean and what's going on in code to produce them. It then goes on to discuss kernel locks, briefly looks at procfs and memory allocation, and closes (as each chapter does) with pointers to where to look in the source for the subjects discussed.

Chapters 3 and 4 flesh out basic concepts more, and then after that the book goes into details, picking both real world and fanciful examples of hardware and giving sample device drivers. Simple devices are presented first, while later chapters get into more complicated hardware, but in each case the same general format is followed: overview of the how and why, sample driver(s), how to most easily debug, and pointers to real kernel sources.

Very well done. I have no complaints - oh, a few minor typos, maybe, but nothing serious.
Comment | 
Was this review helpful to you?
Most Recent Customer Reviews
5.0 out of 5 stars Really good written book, covers nearly all of the driving issues,...
Really good written book, covers nearly all of the driving issues, also the fancy ones! Good assistance to Linux Driver 3rd by O'reilly.I found no better explanation i.e. Read more
Published 19 months ago by Peter Wein
4.0 out of 5 stars Great book!
I was looking for a book on Linux device drives also contains about drivers for embedded devices. This book has that and more else.
Published 19 months ago by Cassiano
5.0 out of 5 stars Good book to have in addition to Linux Device Drivers O'riellly book
I am using this as a reference and also to learn the basics of some of the device driver fundamentals. For the latter part, it offers better scope than the Orielly book IMO.
Published 20 months ago by Amazoner777
5.0 out of 5 stars prefer this book than O'Reilly "Linux Device Drivers"
It is not an easy task to discuss big system. Maybe this is the reason that not many good linux driver books available and comparison among books mainly focus on this book and... Read more
Published on November 6, 2011 by Yan Zhu
5.0 out of 5 stars A tour-de-force
Five stars. ELDD has it (almost) all.

ELDD now sits on the top shelf with other key reference books (and side-by-side with the older Linux Device Drivers, which it... Read more
Published on August 3, 2011 by Phyllis McNaughton
5.0 out of 5 stars It does what is says on the tin.
Obviously, some people have been disappointed by this book. It has to be remembered that it is not called "OS Theory", "How to Write a Device Driver" or "Introduction to the Linux... Read more
Published on January 6, 2011 by D. Alexander
4.0 out of 5 stars Good reference book
This is a good reference book. I'm a sr. software engineer with over 20 years experience and working with Linux the last 10 years or so. Read more
Published on November 24, 2010 by BigDaddy
5.0 out of 5 stars Up to date and Comprehensive
This book deals with the modern 2.6.23/24 kernel and aspects of all types of drivers. The Explanations are clear and to the point and the code examples are well documented. Read more
Published on March 28, 2010 by E. J. Shanab
5.0 out of 5 stars Excellent
Great book. It takes the most interesting stuff about Linux device drivers. There are not a single book that can cover all topics, nevertheless this one is a great companion when... Read more
Published on February 10, 2010 by Fco Javier Rodriguez
1.0 out of 5 stars Copy and paste of device drivers
If you really want to understand how linux device drivers works, do not buy this book. If you just want to take a look what kind of device drivers are there and how it roughly... Read more
Published on December 15, 2009 by S. Choi
Search Customer Reviews
Search these reviews only

What Other Items Do Customers Buy After Viewing This Item?


There are no discussions about this product yet.
Be the first to discuss this product with the community.
Start a new discussion
First post:
Prompts for sign-in