Changeset 364 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/Device


Ignore:
Timestamp:
Mar 27, 2012, 4:21:58 PM (13 years ago)
Author:
aitotat@…
google:author:
aitotat@gmail.com
Message:

Changes to XTIDE Universal BIOS:

  • Advanced ATA Module variables are now kept in DPTs.
  • Forced full mode when using Advanced ATA Module.
Location:
trunk/XTIDE_Universal_BIOS/Src/Device/IDE
Files:
2 edited

Legend:

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

    r363 r364  
    5858;       Nothing
    5959;   Corrupts registers:
    60 ;       AX, CX, DX
     60;       AX, BX, CX
    6161;--------------------------------------------------------------------
    6262.StorePioMode:
    63     call    AtaID_GetMaxPioModeToAXandMinCycleTimeToDX
    64     call    AtaID_ConvertPioModeFromAXandMinCycleTimeFromDXtoActiveAndRecoveryTime
    65     mov     [di+DPT_ATA.bPioMode], al
    66     mov     [di+DPT_ADVANCED_ATA.wMinPioActiveTimeNs], cx
    67     mov     [di+DPT_ADVANCED_ATA.wMinPioRecoveryTimeNs], dx
     63    call    AtaID_GetMaxPioModeToAXandMinCycleTimeToCX
     64    mov     [di+DPT_ADVANCED_ATA.wMinPioCycleTime], cx
     65    mov     [di+DPT_ADVANCED_ATA.bPioMode], al
     66    or      [di+DPT.bFlagsHigh], ah
    6867
    6968;--------------------------------------------------------------------
     
    7978;--------------------------------------------------------------------
    8079.DetectAdvancedIdeController:
    81     mov     dx, [cs:bp+IDEVARS.wPort]
    82     mov     [di+DPT_ADVANCED_ATA.wIdeBasePort], dx
    83     call    AdvAtaInit_DetectControllerForIdeBaseInDX
     80    call    AccessDPT_GetIdeBasePortToBX
     81    call    AdvAtaInit_DetectControllerForIdeBaseInBX
    8482    mov     [di+DPT_ADVANCED_ATA.wControllerID], ax ; Store zero if none detected
    85     mov     [di+DPT_ADVANCED_ATA.wControllerBasePort], cx
     83    mov     [di+DPT_ADVANCED_ATA.wControllerBasePort], dx
    8684    jnc     SHORT .NoAdvancedControllerDetected
    8785
     
    9088    call    AdvAtaInit_GetControllerMaxPioModeToAL
    9189    jnc     SHORT .ChangeTo32bitDevice
    92     MIN_U   [di+DPT_ATA.bPioMode], al
     90    and     BYTE [di+DPT.bFlagsHigh], ~FLGH_DPT_IORDY   ; No IORDY supported if need to limit
     91    MIN_U   [di+DPT_ADVANCED_ATA.bPioMode], al
    9392
    9493    ; We have detected 32-bit controller so change Device Type since
    9594    ; it might have been set to 16-bit on IDEVARS
    9695.ChangeTo32bitDevice:
    97     mov     BYTE [di+DPT_ATA.bDevice], DEVICE_32BIT_ATA
     96    mov     BYTE [di+DPT_ADVANCED_ATA.bDevice], DEVICE_32BIT_ATA
    9897
    9998.NoAdvancedControllerDetected:
     
    136135IdeDPT_StoreDeviceTypeFromIdevarsInCSBPtoDPTinDSDI:
    137136    mov     al, [cs:bp+IDEVARS.bDevice]
    138     mov     [di+DPT_ATA.bDevice], al
     137    mov     [di+DPT_ADVANCED_ATA.bDevice], al
    139138    ret
     139
    140140%endif
  • trunk/XTIDE_Universal_BIOS/Src/Device/IDE/IdeTransfer.asm

    r363 r364  
    189189    mov     dx, [cs:bx+IDEVARS.wPort]           ; Load IDE Data port address
    190190%ifdef MODULE_ADVANCED_ATA
    191     mov     bl, [di+DPT_ATA.bDevice]
     191    mov     bl, [di+DPT_ADVANCED_ATA.bDevice]
    192192%else
    193193    mov     bl, [cs:bx+IDEVARS.bDevice]         ; Load device type to BX
Note: See TracChangeset for help on using the changeset viewer.