Changeset 232 in xtideuniversalbios


Ignore:
Timestamp:
Feb 4, 2012, 12:42:17 PM (11 years ago)
Author:
aitotat@…
google:author:
aitotat@gmail.com
Message:

Changes to XTIDE Universal BIOS:

  • Minor improvements to AH=24h (Set Block Mode).
Location:
trunk/XTIDE_Universal_BIOS
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/XTIDE_Universal_BIOS/Inc/CustomDPT.inc

    r227 r232  
    2828    .dpt                        resb    DPT_size
    2929
    30     ; Block size is specified in sectors (1, 2, 4, 8, 16, 32 or 64).
    31     ; 128 is not allowed to prevent offset overflow during data transfer.
     30    ; Block size is specified in sectors (1, 2, 4, 8, 16, 32, 64 or 128)
    3231    .wSetAndMaxBlock:
    3332    .bSetBlock                  resb    1   ; Current block size (at least 1)
  • trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h/AH24h_HSetBlocks.asm

    r218 r232  
    2020;       CF:     0 if succesfull, 1 if error
    2121;--------------------------------------------------------------------
    22 ALIGN JUMP_ALIGN
    2322AH24h_HandlerForSetMultipleBlocks:
    24     test    BYTE [di+DPT.bFlagsHigh], FLGH_DPT_BLOCK_MODE_SUPPORTED
    25     jnz     SHORT .TryToSetBlockMode
    26     stc
    27     mov     ah, RET_HD_INVALID
    28     jmp     Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH
    29 
    30 ALIGN JUMP_ALIGN
    31 .TryToSetBlockMode:
    3223%ifndef USE_186
    3324    call    AH24h_SetBlockSize
     
    5142;       AL, BX, CX, DX
    5243;--------------------------------------------------------------------
    53 ;ALIGN JUMP_ALIGN
    5444AH24h_SetBlockSize:
    5545    push    ax
    5646    xchg    dx, ax          ; DL = Block size (Sector Count Register)
     47    or      BYTE [di+DPT.bFlagsHigh], FLGH_DPT_BLOCK_MODE_SUPPORTED ; Assume success
    5748    mov     al, COMMAND_SET_MULTIPLE_MODE
    5849    mov     bx, TIMEOUT_AND_STATUS_TO_WAIT(TIMEOUT_DRDY, FLG_STATUS_DRDY)
     
    6152    jnc     .StoreBlockSize
    6253    mov     bl, 1   ; Disable block mode
     54    and     BYTE [di+DPT.bFlagsHigh], ~FLGH_DPT_BLOCK_MODE_SUPPORTED
    6355.StoreBlockSize:    ; Store new block size to DPT and return
    6456    mov     [di+DPT_ATA.bSetBlock], bl
Note: See TracChangeset for help on using the changeset viewer.