Linux_Device_Drivers.pdf
(
8704 KB
)
Pobierz
,TITLE.9502 Page i Thursday, January 27, 2005 12:06 PM
LINUX
DEVICE
DRIVERS
,TITLE.9502 Page ii Thursday, January 27, 2005 12:06 PM
Other Linux resources from O’Reilly
Related titles
Understanding the Linux
Kernel
Linux in a Nutshell
Running Linux
Linux Network
Administrator’s Guide
Linux Pocket Guide
Building Embedded Linux
Systems
Designing Embedded
Hardware
Linux Books
Resource Center
linux.oreilly.com
is a complete catalog of O’Reilly’s books on
Linux and Unix and related technologies, including sample
chapters and code examples.
ONLamp.com
is the premier site for the open source web plat-
form: Linux, Apache, MySQL, and either Perl, Python, or PHP.
Conferences
O’Reilly brings diverse innovators together to nurture the ideas
that spark revolutionary industries. We specialize in document-
ing the latest tools and systems, translating the innovator’s
knowledge into useful skills for those in the trenches. Visit
con-
ferences.oreilly.com
for our upcoming events.
Safari Bookshelf (safari.oreilly.com) is the premier online refer-
ence library for programmers and IT professionals. Conduct
searches across more than 1,000 books. Subscribers can zero in
on answers to time-critical questions in a matter of seconds.
Read the books on your Bookshelf from cover to cover or sim-
ply flip to the page you need. Try it today with a free trial.
,TITLE.9502 Page iii Thursday, January 27, 2005 12:06 PM
LINUX
DEVICE
DRIVERS
THIRD EDITION
Jonathan Corbet, Alessandro
Rubini, and Greg Kroah-Hartman
Beijing
•
Cambridge
•
Farnham
•
Köln
•
Paris
•
Sebastopol
•
Taipei
•
Tokyo
,COPYRIGHT.10321 Page iv Thursday, January 27, 2005 12:09 PM
Linux Device Drivers, Third Edition
by Jonathan Corbet, Alessandro Rubini, and Greg Kroah-Hartman
Copyright © 2005, 2001, 1998 O’Reilly Media, Inc. All rights reserved.
Printed in the United States of America.
Published by O’Reilly Media, Inc., 1005 Gravenstein Highway North, Sebastopol, CA 95472.
O’Reilly books may be purchased for educational, business, or sales promotional use. Online editions
are also available for most titles (safari.oreilly.com). For more information, contact our corporate/insti-
tutional sales department: (800) 998-9938 or
corporate@oreilly.com.
Editor:
Production Editor:
Production Services:
Cover Designer:
Interior Designer:
Printing History:
February 1998:
June 2001:
February 2005:
Andy Oram
Matt Hutchinson
Octal Publishing, Inc.
Edie Freedman
Melanie Wang
First Edition.
Second Edition.
Third Edition.
Nutshell Handbook, the Nutshell Handbook logo, and the O’Reilly logo are registered trademarks of
O’Reilly Media, Inc. The
Linux
series designations,
Linux Device Drivers,
images of the American West,
and related trade dress are trademarks of O’Reilly Media, Inc.
Many of the designations used by manufacturers and sellers to distinguish their products are claimed as
trademarks. Where those designations appear in this book, and O’Reilly Media, Inc. was aware of a
trademark claim, the designations have been printed in caps or initial caps.
While every precaution has been taken in the preparation of this book, the publisher and authors
assume no responsibility for errors or omissions, or for damages resulting from the use of the
information contained herein.
This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 2.0
License. To view a copy of this license, visit
http://creativecommons.org/licenses/by-sa/2.0/
or send a
letter to Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA.
This book uses RepKover
™
a durable and flexible lay-flat binding.
,
ISBN: 0-596-00590-3
[M]
,ldr3TOC.fm.4587 Page v Thursday, January 20, 2005 9:30 AM
Table of Contents
Preface
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
xi
1. An Introduction to Device Drivers
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
1
The Role of the Device Driver
Splitting the Kernel
Classes of Devices and Modules
Security Issues
Version Numbering
License Terms
Joining the Kernel Development Community
Overview of the Book
2
4
5
8
10
11
12
12
2. Building and Running Modules
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
15
Setting Up Your Test System
The Hello World Module
Kernel Modules Versus Applications
Compiling and Loading
The Kernel Symbol Table
Preliminaries
Initialization and Shutdown
Module Parameters
Doing It in User Space
Quick Reference
15
16
18
22
28
30
31
35
37
39
3. Char Drivers
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
42
The Design of scull
Major and Minor Numbers
Some Important Data Structures
42
43
49
v
Plik z chomika:
Amiga789
Inne pliki z tego folderu:
(B-A)Slayers_The_Book_of_Spells_-_03_(5C412788).mkv
(306571 KB)
!!!!! klara repair.rar
(7753 KB)
!!! KULTURNÍ PŘEHLED !!!.odt
(15 KB)
(04) 2010 Test fotografické paměti-text a barvy- animovane 2010 - avi, filmy, komedie,zábava,fotopaměť.pps
(1208 KB)
(4)BurbenogTDv2.32.w3x
(322 KB)
Inne foldery tego chomika:
198.199.95.116
51pegasib.free.fr
75.86.91.167 Aescula
Adventure Legends
Ami64.com Free Downloads
Zgłoś jeśli
naruszono regulamin