Changeset 35 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h.asm


Ignore:
Timestamp:
Aug 24, 2010, 6:44:44 PM (14 years ago)
Author:
aitotat
google:author:
aitotat
Message:

Cleaned recent changes a bit to save few bytes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h.asm

    r32 r35  
    22; Project name  :   IDE BIOS
    33; Created date  :   21.9.2007
    4 ; Last update   :   1.8.2010
     4; Last update   :   24.8.2010
    55; Author        :   Tomi Tilli
    66; Description   :   Int 13h BIOS functions (Floppy and Hard disk).
     
    9595    ; Special return processing required if target function
    9696    ; returns something in DL
    97     mov     di, Int13h_ReturnFromAnotherBiosWithoutSwappingDrives
     97    mov     di, Int13h_ReturnFromAnotherBiosWithValueInDL
    9898    call    DriveXlate_DoesFunctionReturnSomethingInDL
    9999    jc      SHORT .PushIretAddress
    100     add     di, BYTE Int13h_ReturnFromAnotherBios - Int13h_ReturnFromAnotherBiosWithoutSwappingDrives
     100    add     di, BYTE Int13h_ReturnFromAnotherBios - Int13h_ReturnFromAnotherBiosWithValueInDL
    101101.PushIretAddress:
    102102    pushf                               ; Push FLAGS to simulate INT
     
    133133
    134134;--------------------------------------------------------------------
    135 ; Return handlers from another INT 13h BIOS.
    136 ;
    137 ; Int13h_ReturnFromAnotherBiosWithoutSwappingDrives
     135; Int13h_ReturnFromAnotherBiosWithValueInDL
    138136; Int13h_ReturnFromAnotherBios
    139137;   Parameters:
     
    147145;--------------------------------------------------------------------
    148146ALIGN JUMP_ALIGN
    149 Int13h_ReturnFromAnotherBiosWithoutSwappingDrives:
     147Int13h_ReturnFromAnotherBiosWithValueInDL:
    150148    push    ds
    151149    push    di
    152150    pushf                               ; Store return flags
    153151    call    RamVars_GetSegmentToDS
    154     dec     BYTE [RAMVARS.xlateVars+XLATEVARS.bRecurCnt]
     152    call    DriveXlate_WhenLeavingInt13hWithReturnValueInDL
    155153    jmp     SHORT Int13h_Leave
     154
    156155ALIGN JUMP_ALIGN
    157156Int13h_ReturnFromAnotherBios:
     
    167166; Returns from any BIOS function implemented by this BIOS.
    168167;
    169 ; Int13h_ReturnWithoutSwappingDrives
    170 ; Int13h_StoreErrorCodeToBDAandPopDSDIandReturn
    171 ; Int13h_StoreErrorCodeToBDAandPopXRegsAndReturn
     168; Int13h_ReturnWithValueInDL
    172169; Int13h_PopXRegsAndReturn
    173170; Int13h_PopDiDsAndReturn
     
    181178;--------------------------------------------------------------------
    182179ALIGN JUMP_ALIGN
    183 Int13h_ReturnWithoutSwappingDrives:
     180Int13h_ReturnWithValueInDL:
    184181    pushf
    185     dec     BYTE [RAMVARS.xlateVars+XLATEVARS.bRecurCnt]    ; Preserves CF
    186     call    HError_StoreBiosErrorCodeFromAHtoBDA
    187     jmp     SHORT Int13h_Leave
    188 
    189 ALIGN JUMP_ALIGN
    190 Int13h_StoreErrorCodeToBDAandPopDSDIandReturn:
    191     call    HError_StoreBiosErrorCodeFromAHtoBDA
    192     jmp     SHORT Int13h_PopDiDsAndReturn
    193 
    194 ALIGN JUMP_ALIGN
    195 Int13h_StoreErrorCodeToBDAandPopXRegsAndReturn:
    196     call    HError_StoreBiosErrorCodeFromAHtoBDA
     182    call    DriveXlate_WhenLeavingInt13hWithReturnValueInDL
     183    jmp     SHORT Int13h_LeaveAfterStoringErrorCodeToBDA
     184
    197185ALIGN JUMP_ALIGN
    198186Int13h_PopXRegsAndReturn:
     
    202190    pop     cx
    203191    pop     dx
     192    ; Fall to Int13h_PopDiDsAndReturn
     193
    204194ALIGN JUMP_ALIGN
    205195Int13h_PopDiDsAndReturn:
    206196    pushf
    207197    call    DriveXlate_WhenLeavingInt13h
     198    ; Fall to Int13h_LeaveAfterStoringErrorCodeToBDA
     199
     200Int13h_LeaveAfterStoringErrorCodeToBDA:
     201    LOAD_BDA_SEGMENT_TO ds, di
     202    mov     [BDA.bHDStatus], ah
     203    ; Fall to Int13h_Leave
     204
    208205Int13h_Leave:
    209206    popf
Note: See TracChangeset for help on using the changeset viewer.