]>
wirehaze git hosting - MS-DOS.git/blob - v4.0/src/DEV/SMARTDRV/DEVSYM.ASM
1 BREAK <Device table
and SRH definition
>
3 ; The device table list has the form:
5 SDEVNEXT
DD ?
;Pointer to next device header
6 SDEVATT
DW ?
;Attributes of the device
7 SDEVSTRAT
DW ?
;Strategy entry point
8 SDEVINT
DW ?
;Interrupt entry point
9 SDEVNAME
DB 8 DUP (?
) ;Name of device (only first byte used for block)
18 ; 14 -> 1 if the device understands IOCTL control strings
19 ; 13 -> 1 if the device supports output-until-busy
21 ; 11 -> 1 if the device understands Open/Close
28 ; 4 -> 1 if device is recipient of INT 29h
29 ; 3 -> 1 if device is clock device
30 ; 2 -> 1 if device is null device
31 ; 1 -> 1 if device is console output
32 ; 0 -> 1 if device is console input
37 ; 14 -> 1 if the device understands IOCTL control strings
38 ; 13 -> 1 if the device determines media by examining the FAT ID byte.
39 ; This requires the first sector of the fat to *always* reside in
42 ; 11 -> 1 if the device understands Open/Close/removable media
55 DevTyp EQU 8000H
; Bit 15 - 1 if Char, 0 if block
57 DevIOCtl EQU 4000H
; Bit 14 - CONTROL mode bit
58 ISFATBYDEV EQU 2000H
; Bit 13 - Device uses FAT ID bytes,
60 OutTilBusy EQU 2000h
; Output until busy is enabled
61 ISNET EQU 1000H
; Bit 12 - 1 if a NET device, 0 if
62 ; not. Currently block only.
63 DEVOPCL EQU
0800H ; Bit 11 - 1 if this device has
64 ; OPEN,CLOSE and REMOVABLE MEDIA
65 ; entry points, 0 if not
67 EXTENTBIT EQU
0400H ; Bit 10 - Currently 0 on all devs
68 ; This bit is reserved for future use
69 ; to extend the device header beyond
72 ; NOTE Bit 9 is currently used on IBM systems to indicate "drive is shared".
73 ; See IOCTL function 9. THIS USE IS NOT DOCUMENTED, it is used by some
74 ; of the utilities which are supposed to FAIL on shared drives on server
75 ; machines (FORMAT,CHKDSK,RECOVER,..).
77 ISSPEC EQU
0010H ;Bit 4 - This device is special
78 ISCLOCK EQU
0008H ;Bit 3 - This device is the clock device.
79 ISNULL EQU
0004H ;Bit 2 - This device is the null device.
80 ISCOUT EQU
0002H ;Bit 1 - This device is the console output.
81 ISCIN EQU
0001H ;Bit 0 - This device is the console input.
83 ;Static Request Header
85 REQLEN
DB ?
;Length in bytes of request block
86 REQUNIT
DB ?
;Device unit number
87 REQFUNC
DB ?
;Type of request
88 REQSTAT
DW ?
;Status Word
89 DB 8 DUP(?
) ;Reserved for queue links
93 STERR EQU 8000H
;Bit 15 - Error
94 STBUI EQU
0200H ;Bit 9 - Buisy
95 STDON EQU
0100H ;Bit 8 - Done
96 STECODE EQU
00FFH ;Error code
99 DEVINIT EQU
0 ;Initialization
100 DINITHL EQU
26 ;Size of init header
101 DEVMDCH EQU
1 ;Media check
102 DMEDHL EQU
15 ;Size of media check header
103 DEVBPB EQU
2 ;Get BPB
104 DEVRDIOCTL EQU
3 ;IOCTL read
105 DBPBHL EQU
22 ;Size of Get BPB header
107 DRDWRHL EQU
22 ;Size of RD/WR header
108 DEVRDND EQU
5 ;Non destructive read no wait (character devs)
109 DRDNDHL EQU
14 ;Size of non destructive read header
110 DEVIST EQU
6 ;Input status
111 DSTATHL EQU
13 ;Size of status header
112 DEVIFL EQU
7 ;Input flush
113 DFLSHL EQU
15 ;Size of flush header
115 DEVWRTV EQU
9 ;Write with verify
116 DEVOST EQU
10 ;Output status
117 DEVOFL EQU
11 ;Output flush
118 DEVWRIOCTL EQU
12 ;IOCTL write
119 DEVOPN EQU
13 ;Device open
120 DEVCLS EQU
14 ;Device close
121 DOPCLHL EQU
13 ;Size of OPEN/CLOSE header
122 DEVRMD EQU
15 ;Removable media
123 REMHL EQU
13 ;Size of Removable media header
125 DevOUT EQU
16 ; output until busy.
126 DevOutL EQU DevWrt
; length of output until busy