source: xtideuniversalbios/trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h/AH2h_HRead.asm@ 245

Last change on this file since 245 was 221, checked in by aitotat@…, 13 years ago

Changes to XTIDE Universal BIOS:

  • AH=0Ch (Seek) should work properly again.
  • More than 127 sectors are no longer allowed for EBIOS functions.
  • Changed location for BOOTNFO structs.
File size: 1.5 KB
Line 
1; Project name : XTIDE Universal BIOS
2; Description : Int 13h function AH=2h, Read Disk Sectors.
3
4; Section containing code
5SECTION .text
6
7;--------------------------------------------------------------------
8; Int 13h function AH=2h, Read Disk Sectors.
9;
10; AH2h_HandlerForReadDiskSectors
11; Parameters:
12; AL, CX, DH, ES: Same as in INTPACK
13; DL: Translated Drive number
14; DS:DI: Ptr to DPT (in RAMVARS segment)
15; SS:BP: Ptr to IDEPACK
16; Parameters on INTPACK:
17; AL: Number of sectors to read (1...128)
18; CH: Cylinder number, bits 7...0
19; CL: Bits 7...6: Cylinder number bits 9 and 8
20; Bits 5...0: Starting sector number (1...63)
21; DH: Starting head number (0...255)
22; ES:BX: Pointer to buffer recieving data
23; Returns with INTPACK:
24; AH: Int 13h/40h floppy return status
25; AL: Burst error length if AH returns 11h, undefined otherwise
26; CF: 0 if successfull, 1 if error
27;--------------------------------------------------------------------
28ALIGN JUMP_ALIGN
29AH2h_HandlerForReadDiskSectors:
30 call Prepare_BufferToESSIforOldInt13hTransfer
31 call Prepare_GetOldInt13hCommandIndexToBX
32 mov ah, [cs:bx+g_rgbReadCommandLookup]
33 mov bx, TIMEOUT_AND_STATUS_TO_WAIT(TIMEOUT_DRQ, FLG_STATUS_DRQ)
34%ifdef USE_186
35 push Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH
36 jmp Idepack_TranslateOldInt13hAddressAndIssueCommandFromAH
37%else
38 call Idepack_TranslateOldInt13hAddressAndIssueCommandFromAH
39 jmp Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH
40%endif
Note: See TracBrowser for help on using the repository browser.