Changeset 584 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/Handlers


Ignore:
Timestamp:
Apr 25, 2015, 7:17:41 PM (9 years ago)
Author:
aitotat
google:author:
aitotat
Message:

Changes to XTIDE Universal BIOS:

  • Added support for Lo-tech 8-bit IDE Adapter (untested)
Location:
trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h
Files:
2 edited

Legend:

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

    r567 r584  
    111111    ;       Selected transfer mode is stored in BIOS variable (DPT_ATA.bDevice).
    112112
    113     ; Note that when selecting 'DEVICE_8BIT_PIO_MODE_WITH_BIU_OFFLOAD' mode,
     113    ; Note that when selecting 'DEVICE_8BIT_XTCF_PIO8_WITH_BIU_OFFLOAD' mode,
    114114    ; the ATA device (i.e. CompactFlash card) will operate in 8-bit mode, but
    115115    ; data will be transferred from its data register using 16-bit CPU instructions
     
    134134    dec     ax                      ; XTCF_8BIT_PIO_MODE_WITH_BIU_OFFLOAD = 1
    135135    jz      SHORT .Set8bitPioModeWithBIUOffload
     136    dec     ax
     137    jz      SHORT .Set16bitPioModeWithBIUOffload
    136138
    137139    ; XTCF_DMA_MODE = 2 (allow 3 as well for more optimized code)
     
    144146    mov     al, XTCF_DMA_MODE_MAX_BLOCK_SIZE
    145147    jmp     SHORT AH24h_SetBlockSize
     148
     149.Set16bitPioModeWithBIUOffload:
     150    pop     bx                              ; Do not enable 8-bit PIO...
     151    ePUSH_T bx, AH23h_Disable8bitPioMode    ; ...disable it instead
     152    mov     al, DEVICE_8BIT_XTCF_PIO16_WITH_BIU_OFFLOAD
     153    SKIP2B  bx
    146154
    147155.Set8bitPioMode:
  • trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h/AH23h_HFeatures.asm

    r526 r584  
    7878;--------------------------------------------------------------------
    7979; AH23h_Enable8bitPioMode
     80; AH23h_Disable8bitPioMode
    8081;   Parameters:
    8182;       DS:DI:  Ptr to DPT (in RAMVARS segment)
     
    9192    mov     si, FEATURE_ENABLE_8BIT_PIO_TRANSFER_MODE
    9293    jmp     SHORT AH23h_SetControllerFeatures
     94AH23h_Disable8bitPioMode:
     95    mov     si, FEATURE_DISABLE_8BIT_PIO_TRANSFER_MODE
     96    call    AH23h_SetControllerFeatures
     97    xor     ah, ah          ; Clear error since modern drives might not understand the command and are
     98    ret                     ; always in 16-bit mode anyway
    9399%endif
Note: See TracChangeset for help on using the changeset viewer.