1 | ; Project name : XTIDE Universal BIOS
|
---|
2 | ; Description : Equates used in Enhanced INT 13h functions (EBIOS).
|
---|
3 | %ifndef EBIOS_INC
|
---|
4 | %define EBIOS_INC
|
---|
5 |
|
---|
6 | ; EBIOS specification returned by INT 13h, AH=41h
|
---|
7 | EBIOS_VERSION EQU 21h ; 21h = EDD version 1.1
|
---|
8 |
|
---|
9 | ; Support bits returned by INT 13h, AH=41h
|
---|
10 | ENHANCED_DRIVE_ACCESS_SUPPORT EQU (1<<0) ; 41h, 42h, 43h 44h, 47h and 48h are available
|
---|
11 | DRIVE_LOCKING_AND_EJECTING_SUPPORT EQU (1<<1) ; 41h, 45h, 46h, 48h, 49h are available and INT 15h, AH=52h
|
---|
12 | ENHANCED_DISK_DRIVE_SUPPORT EQU (1<<2) ; 41h, 48h, 4Eh are available (EDD)
|
---|
13 |
|
---|
14 |
|
---|
15 | ; Extended Drive Information returned by AH=48h
|
---|
16 | struc EDRIVE_INFO
|
---|
17 | .wSize resb 2 ; 0, Size of this buffer, at least 26
|
---|
18 | .wFlags resb 2 ; 2, Information flags
|
---|
19 | .dwCylinders resb 4 ; 4, Total number of addressable cylinders
|
---|
20 | .dwHeads resb 4 ; 8, Total number of addressable heads
|
---|
21 | .dwSectorsPerTrack resb 4 ; 12, Number of sectors per track
|
---|
22 | .qwTotalSectors resb 8 ; 16, Total number of addressable sectors
|
---|
23 | .wSectorSize resb 2 ; 24, Number of bytes per sector
|
---|
24 | .fpEDDparams resb 8 ; 26, Optional pointer to Enhanced Disk Drive (EDD) configuration parameters
|
---|
25 | endstruc
|
---|
26 |
|
---|
27 | MINIMUM_EDRIVEINFO_SIZE EQU 26 ; 26 bytes does not include EDD pointer
|
---|
28 |
|
---|
29 | ; Flags for EDRIVE_INFO.wFlags
|
---|
30 | FLG_DMA_BOUNDARY_ERRORS_HANDLED_BY_BIOS EQU (1<<0)
|
---|
31 | FLG_CHS_INFORMATION_IS_VALID EQU (1<<1)
|
---|
32 | FLG_REMOVABLE_DRIVE EQU (1<<2)
|
---|
33 | FLG_WRITE_WITH_VERIFY_SUPPORTED EQU (1<<3)
|
---|
34 | FLG_CHANGE_LINE_SUPPORT EQU (1<<4) ; Removable media only
|
---|
35 | FLG_LOCKABLE EQU (1<<5) ; Removable media only
|
---|
36 | FLG_NO_MEDIA_PRESENT_AND_CHS_SET_TO_MAX EQU (1<<6) ; Removable media only
|
---|
37 |
|
---|
38 |
|
---|
39 | ; Disk Address Packet for read, write and verify functions
|
---|
40 | struc DAP
|
---|
41 | .bSize resb 1 ; 0, Size of this packet in bytes
|
---|
42 | .bReservedAt1 resb 1 ; 1, Currently unused, must be zero
|
---|
43 | .wSectorCount resb 1 ; 2, Number of sectors to process (0...127)
|
---|
44 | .dwMemoryAddress:
|
---|
45 | .wOffset resb 2 ; 4, Memory offset for transfer
|
---|
46 | .wSegment resb 2 ; 6, Memory segment for transfer
|
---|
47 | .qwLBA resb 8 ; 8, Starting sector for transfer
|
---|
48 | endstruc
|
---|
49 |
|
---|
50 | MINIMUM_DAP_SIZE EQU 16
|
---|
51 |
|
---|
52 |
|
---|
53 | %endif ; EBIOS_INC
|
---|