[165] | 1 | ; Project name : XTIDE Universal BIOS |
---|
| 2 | ; Description : Equates used in Enhanced INT 13h functions (EBIOS). |
---|
[376] | 3 | |
---|
| 4 | ; |
---|
[526] | 5 | ; XTIDE Universal BIOS and Associated Tools |
---|
| 6 | ; Copyright (C) 2009-2010 by Tomi Tilli, 2011-2013 by XTIDE Universal BIOS Team. |
---|
[376] | 7 | ; |
---|
| 8 | ; This program is free software; you can redistribute it and/or modify |
---|
| 9 | ; it under the terms of the GNU General Public License as published by |
---|
| 10 | ; the Free Software Foundation; either version 2 of the License, or |
---|
| 11 | ; (at your option) any later version. |
---|
[526] | 12 | ; |
---|
[376] | 13 | ; This program is distributed in the hope that it will be useful, |
---|
| 14 | ; but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
| 15 | ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
[526] | 16 | ; GNU General Public License for more details. |
---|
[376] | 17 | ; Visit http://www.gnu.org/licenses/old-licenses/gpl-2.0.html |
---|
| 18 | ; |
---|
| 19 | |
---|
[165] | 20 | %ifndef EBIOS_INC |
---|
| 21 | %define EBIOS_INC |
---|
| 22 | |
---|
| 23 | ; EBIOS specification returned by INT 13h, AH=41h |
---|
| 24 | EBIOS_VERSION EQU 21h ; 21h = EDD version 1.1 |
---|
| 25 | |
---|
| 26 | ; Support bits returned by INT 13h, AH=41h |
---|
| 27 | ENHANCED_DRIVE_ACCESS_SUPPORT EQU (1<<0) ; 41h, 42h, 43h 44h, 47h and 48h are available |
---|
| 28 | DRIVE_LOCKING_AND_EJECTING_SUPPORT EQU (1<<1) ; 41h, 45h, 46h, 48h, 49h are available and INT 15h, AH=52h |
---|
[170] | 29 | ENHANCED_DISK_DRIVE_SUPPORT EQU (1<<2) ; 41h, 48h, 4Eh are available (EDD) |
---|
[165] | 30 | |
---|
| 31 | |
---|
| 32 | ; Extended Drive Information returned by AH=48h |
---|
| 33 | struc EDRIVE_INFO |
---|
| 34 | .wSize resb 2 ; 0, Size of this buffer, at least 26 |
---|
| 35 | .wFlags resb 2 ; 2, Information flags |
---|
| 36 | .dwCylinders resb 4 ; 4, Total number of addressable cylinders |
---|
| 37 | .dwHeads resb 4 ; 8, Total number of addressable heads |
---|
| 38 | .dwSectorsPerTrack resb 4 ; 12, Number of sectors per track |
---|
| 39 | .qwTotalSectors resb 8 ; 16, Total number of addressable sectors |
---|
| 40 | .wSectorSize resb 2 ; 24, Number of bytes per sector |
---|
| 41 | .fpEDDparams resb 8 ; 26, Optional pointer to Enhanced Disk Drive (EDD) configuration parameters |
---|
| 42 | endstruc |
---|
| 43 | |
---|
| 44 | MINIMUM_EDRIVEINFO_SIZE EQU 26 ; 26 bytes does not include EDD pointer |
---|
| 45 | |
---|
| 46 | ; Flags for EDRIVE_INFO.wFlags |
---|
| 47 | FLG_DMA_BOUNDARY_ERRORS_HANDLED_BY_BIOS EQU (1<<0) |
---|
| 48 | FLG_CHS_INFORMATION_IS_VALID EQU (1<<1) |
---|
| 49 | FLG_REMOVABLE_DRIVE EQU (1<<2) |
---|
| 50 | FLG_WRITE_WITH_VERIFY_SUPPORTED EQU (1<<3) |
---|
| 51 | FLG_CHANGE_LINE_SUPPORT EQU (1<<4) ; Removable media only |
---|
| 52 | FLG_LOCKABLE EQU (1<<5) ; Removable media only |
---|
| 53 | FLG_NO_MEDIA_PRESENT_AND_CHS_SET_TO_MAX EQU (1<<6) ; Removable media only |
---|
| 54 | |
---|
| 55 | |
---|
| 56 | ; Disk Address Packet for read, write and verify functions |
---|
| 57 | struc DAP |
---|
| 58 | .bSize resb 1 ; 0, Size of this packet in bytes |
---|
| 59 | .bReservedAt1 resb 1 ; 1, Currently unused, must be zero |
---|
[223] | 60 | .wSectorCount resb 2 ; 2, Number of sectors to process (0...127) |
---|
[165] | 61 | .dwMemoryAddress: |
---|
| 62 | .wOffset resb 2 ; 4, Memory offset for transfer |
---|
| 63 | .wSegment resb 2 ; 6, Memory segment for transfer |
---|
| 64 | .qwLBA resb 8 ; 8, Starting sector for transfer |
---|
| 65 | endstruc |
---|
| 66 | |
---|
| 67 | MINIMUM_DAP_SIZE EQU 16 |
---|
| 68 | |
---|
| 69 | |
---|
| 70 | %endif ; EBIOS_INC |
---|