Changeset 475 in xtideuniversalbios


Ignore:
Timestamp:
Oct 12, 2012, 8:21:26 PM (9 years ago)
Author:
aitotat@…
google:author:
aitotat@gmail.com
Message:

Changes to XTIDE Universal BIOS:

  • Fixed a bug that might have set CF flag when returning from memory mapped transfers.
Location:
trunk/XTIDE_Universal_BIOS/Src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/XTIDE_Universal_BIOS/Src/Device/IDE/JrIdeTransfer.asm

    r474 r475  
    100100;               1 if any error
    101101;   Corrupts registers:
    102 ;       AL, BX, DX, SI, ES
     102;       AL, BX, DX, SI
    103103;--------------------------------------------------------------------
    104104ReadFromSectorAccessWindow:
     
    107107    jc      SHORT ReturnWithMemoryIOtransferErrorInAH
    108108
    109     mov     cx, [bp+MEMPIOVARS.wSectorsInBlock]
     109    mov     cx, [bp+MEMPIOVARS.wSectorsInBlock] ; Clears CH
    110110    cmp     [bp+MEMPIOVARS.bSectorsLeft], cl
    111111    jbe     SHORT .ReadLastBlockFromDrive
     
    138138
    139139    ; All sectors successfully transferred
    140     add     cx, [bp+PIOVARS.bSectorsDone]       ; Never sets CF
     140    add     cl, [bp+MEMPIOVARS.bSectorsDone]    ; Never sets CF
    141141    ret
    142142
     
    145145    lds     di, [bp+MEMPIOVARS.fpDPT]           ; DPT now in DS:DI
    146146%ifdef USE_386
    147     movzx   cx, [bp+MEMPIOVARS.bSectorsDone]
     147    movzx   cx, BYTE [bp+MEMPIOVARS.bSectorsDone]
    148148%else
    149     mov     ch, 0
     149    mov     ch, 0                               ; Preserve CF
    150150    mov     cl, [bp+MEMPIOVARS.bSectorsDone]
    151151%endif
     
    220220    xor     cl, cl
    221221ALIGN JUMP_ALIGN
    222 .WriteBlock:
     222.WriteNextSector:
    223223    mov     ch, SECTOR_ACCESS_WINDOW_SIZE >> 9
    224224    rep movsw
    225225    mov     di, bx  ; Reset for next sector
    226226    dec     dx
    227     jnz     SHORT .WriteBlock
     227    jnz     SHORT .WriteNextSector
    228228    ret
    229229
     
    232232; ReadSingleBlockFromSectorAccessWindowInDSSItoESDI
    233233;   Parameters:
    234 ;       CX      Number of sectors in block
     234;       CX      Number of sectors in full block or sectors in last partial block
    235235;       ES:DI:  Normalized ptr to buffer to receive data (destination)
    236236;       DS:SI:  Ptr to Sector Access Window (source)
     
    247247    xor     cl, cl
    248248ALIGN JUMP_ALIGN
    249 .ReadBlock:
     249.ReadNextSector:
    250250    mov     ch, SECTOR_ACCESS_WINDOW_SIZE >> 9
    251251    rep movsw
    252252    mov     si, bx  ; Reset for next sector
    253253    dec     dx
    254     jnz     SHORT .ReadBlock
     254    jnz     SHORT .ReadNextSector
    255255    ret
    256256
  • trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h/AH1Eh_XTCF.asm

    r474 r475  
    3939AH1Eh_HandlerForXTCFfeatures:
    4040%ifndef USE_186
    41     call    AH1Eh_ProcessXTCFsubcommandFromAL
     41    call    ProcessXTCFsubcommandFromAL
    4242    jmp     Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH
    4343%else
    4444    push    Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH
    45     ; Fall to AH1Eh_ProcessXTCFsubcommandFromAL
     45    ; Fall to ProcessXTCFsubcommandFromAL
    4646%endif
    4747
    4848
    4949;--------------------------------------------------------------------
    50 ; AH1Eh_ProcessXTCFsubcommandFromAL
     50; ProcessXTCFsubcommandFromAL
    5151;   Parameters:
    5252;       AL:     XT-CF subcommand (see XTCF.inc for more info)
     
    5959;       AL, BX, CX, DX, SI
    6060;--------------------------------------------------------------------
    61 AH1Eh_ProcessXTCFsubcommandFromAL:
     61ProcessXTCFsubcommandFromAL:
    6262    ; IS_THIS_DRIVE_XTCF. We check this for all commands.
    6363    call    AccessDPT_IsThisDeviceXTCF
Note: See TracChangeset for help on using the changeset viewer.