AA-2600E-TC RSX-11M Guide to Writing an I-O Driver.pdf

(13930 KB) Pobierz
RSX-11 M
Guide to Writing an I/O Driver
Order No
.
AA-2600E-TC
RSX-11M
Guide to Writing an I/O Driver
Order No. AA-2600E-
Te
~.--­
~~--
c
RSX-11 M Version 4.0
c
digital equipment corporation · mayndrd,massachusetts
c
First Printing, April
Revised, September
Revised, November
Revised, December
Updated, May
Revised, November
1975
1975
1976
1977
1979
1981
The information in this document is subject to change without notice
and should not be construed as a commitment by Digital Equipment
Corporation. Digital Equipment Corporation assumes no responsibility
for any errors that may appear in this document.
The software described in this document is furnished under a license
and may be used or copied only in accordance with the terms of such
license.
No responsibility is assumed for the use or reliability of software on
equipment that is not supplied by Digital Equipment Corporation or its
affiliated companies.
Copyright
0
1975,1976,1977,1979,1981 Digital Equipment Corporation
All Rights Reserved.
(
Printed in U.S.A.
The postpaid READER'S COMMENTS form on the last page of this document
requests the user's critical evaluation to assist in preparing future
documentation.
The following are trademarks of Digital Equipment Corporation:
DEC
DECnet
DECsystem-l0
DECSYSTEM-20
DECUS
DECwriter
DIBOL
EduSystem
lAS
MASSBUS
PDP
PDT
RSTS
RSX
UNIBUS
VAX
VMS
c
VT
~DmDDmD
ZK2048
c
(
CONTENTS
Page
PREFACE
SUMMARY OF TECHNICAL CHANGES
CHAPTER 1
1.1
1.2
CHAPTER 2
2.1
2.2
2.2.1
2.2.1.1
2.2.1.2
2.2.1.3
2.2.2
2.2.2.1
2.2.2.2
2.2.2.3
2.2.2.4
2.2.2.5
2.2.2.6
2.3
2.3.1
2.3.2
2.3.3
2.3.3.1
2.3.4
2.3.5
2.3.6
2.3.7
2.4
2.4.1
2.4.2
2.4.2.1
2.4.2.2
2.4.2.3
2.4.2.4
2.5
2.5.1
2.5.2
2.5.3
2.5.3.1
INTRODUCTION TO I/O DRIVERS
RESIDENT AND LOADABLE DRIVERS
FUNCTION OF AN I/O DRIVER
• • • • • • • • • • 1-1
• • • • •
• 1-2
vii
ix
THE RSX-llM I/O SYSTEM--PHILOSOPHY AND STRUCTURE
I/O PHILOSOPHY •
STRUCTURE
I/O Hierarchy
FCS/RMS
QIO
• •
c
• • • • • • •
• • •
• • •
.
. • •
.
.
• • •
. • .
2-1
2-1
2-1
2-2
• • • •
• • • • • • 2-2
Executive I/O Processing • • • • • • • • •
2-3
Role of I/O Driver in RSX-llM
• • • • • • • 2-3
Device Interrupt • • • • • • • • • • • • •
2-4
I/O Initiator
•••••
• • • • • 2-4
Device Time-out
• • • • • 2-4
Cancel I/O • • •
••••••••• •
2-4
Power Failure
• • • • • • • • • • 2-4
Summary--Role of an I/O Driver
• • • •
~
• 2-5
DATA STRUCTURES
• • •
• • • • • • • • • • • •
2-5
The Device Control Block (DCB) • • • •
2-6
The Unit Control Block (UCB) • • • • • • •
• 2-6
The Status Control Block (SCB)
• 2-6
Interrelation of the I/O Control
Blocks 2-6
The I/O Packet • • • •
• • •
.~.
• • • • • 2-8
The I/O Queue
• • • •
• 2-9
The Fork List
• • • • • • • • 2-9
The Device Interrupt Vector
• • • •
2-10
EXECUTIVE SERVICES • • • • • •
• • • ••
2-10
Pre-Driver Initiation Processing • • • • • • •
2-11
Post-Driver Initiation Services • • • •
2-11
Interrupt Save ($INTSV)
• • • • • • ••
2-12
Get Packet ($GTPKT)
•••••
• • ••
2-12
Create Fork Process ($FORK)
••••
2-12
I/O Done ($IODON or $IOALT)
••••••••
2-13
PROGRAMMING STANDARDS • • • • • • • •
2-13
Process-Like Characteristics of a Driver •
2-13
Programming Conventions • • • • •
2-13
Programming Protocol • • • • • • • • • • •
2-14
Processing at Priority 7 with
Inte~rupts
2-14
Locked Out • • • • • • • •
2.5.3.2
Processing at the Priority of the
2-14
Interrupting Source
iii
Zgłoś jeśli naruszono regulamin