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

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

Changes to XTIDE Universal BIOS:

  • Hopefully this commit is successful. Sorry for the mess.
File size: 1.6 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 .WriteWithVerifyNotSupported
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
42
43.WriteWithVerifyNotSupported:
44    jmp     AH2h_ExitInt13hSinceSectorCountInIntpackIsZero
Note: See TracBrowser for help on using the repository browser.