source: xtideuniversalbios/trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h/EBIOS/AH43h_ExtendedWriteSectors.asm@ 186

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

Changes to XTIDE Universal BIOS:

  • Old Int 13h functions can now transfer 256 sectors per call.
  • eINT 13h functions can now transfer 65535 sectors per call.
File size: 1.5 KB
Line 
1; Project name : XTIDE Universal BIOS
2; Description : Int 13h function AH=43h, Extended Write Sectors.
3
4; Section containing code
5SECTION .text
6
7;--------------------------------------------------------------------
8; Int 13h function AH=43h, Extended Write Sectors.
9;
10; AH43h_HandlerForExtendedWriteSectors
11; Parameters:
12; SI: 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: 0 or 1 to write with verify off
18; 2 to write with verify (if supported)
19; DS:SI: Ptr to Disk Address Packet
20; Returns with INTPACK:
21; AH: Int 13h return status
22; CF: 0 if succesfull, 1 if error
23; Return with Disk Address Packet in INTPACK:
24; .bSectorCount Number of sectors written successfully
25;--------------------------------------------------------------------
26ALIGN JUMP_ALIGN
27AH43h_HandlerForExtendedWriteSectors:
28 cmp BYTE [bp+IDEPACK.intpack+INTPACK.al], 2 ; Verify requested?
29 jae SHORT AH42h_ReturnWithInvalidFunctionError
30
31 call AH42h_LoadDapToESSIandVerifyForTransfer
32 call CommandLookup_GetEbiosIndexToBX
33 mov ah, [cs:bx+g_rgbWriteCommandLookup]
34 mov bx, TIMEOUT_AND_STATUS_TO_WAIT(TIMEOUT_DRQ, FLG_STATUS_DRQ)
35%ifdef USE_186
36 push Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH
37 jmp Idepack_ConvertDapToIdepackAndIssueCommandFromAH
38%else
39 call Idepack_ConvertDapToIdepackAndIssueCommandFromAH
40 jmp Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH
41%endif
Note: See TracBrowser for help on using the repository browser.