Changeset 442 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/Device/IDE


Ignore:
Timestamp:
Aug 21, 2012, 5:17:11 PM (12 years ago)
Author:
aitotat@…
google:author:
aitotat@gmail.com
Message:

Changes to XTIDE Universal BIOS:

  • ATA ID validation now compares heads to correct maximum number of heads.
  • Added XTCF 8-bit mode transfer functions.
Location:
trunk/XTIDE_Universal_BIOS/Src/Device/IDE
Files:
2 edited

Legend:

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

    r439 r442  
    7575
    7676    ; Wait until drive motors have reached max speed
    77     cmp     bp, BYTE ROMVARS.ideVars0
     77    cmp     bp, BYTE ROMVARS.ideVars0       ; First controller?
    7878    jne     SHORT .SkipLongWaitSinceDriveIsNotPrimaryMaster
    79     test    bh, FLG_DRVNHEAD_DRV
     79    test    bh, FLG_DRVNHEAD_DRV            ; Wait already done for Master
    8080    jnz     SHORT .SkipLongWaitSinceDriveIsNotPrimaryMaster
    8181    call    AHDh_WaitUnilDriveMotorHasReachedFullSpeed
  • trunk/XTIDE_Universal_BIOS/Src/Device/IDE/IdeTransfer.asm

    r421 r442  
    273273%endif
    274274
     275;--------------------------------------------------------------------
     276ALIGN JUMP_ALIGN
     277ReadBlockFromXTCF:
     278    UNROLL_SECTORS_IN_CX_TO_DWORDS
     279ALIGN JUMP_ALIGN
     280.ReadNextDword:
     281    in      al, dx      ; Read 1st BYTE
     282    stosb               ; Store 1st BYTE to [ES:DI]
     283    in      al, dx
     284    stosb
     285
     286    in      al, dx
     287    stosb
     288    in      al, dx
     289    stosb
     290    loop    .ReadNextDword
     291    ret
     292
    275293%endif  ; MODULE_8BIT_IDE
    276294
     
    352370;--------------------------------------------------------------------
    353371ALIGN JUMP_ALIGN
    354 WriteBlockToFastXtide:
    355     UNROLL_SECTORS_IN_CX_TO_QWORDS
     372WriteBlockToXTCF:
     373    UNROLL_SECTORS_IN_CX_TO_DWORDS
    356374    push    ds
    357375    push    es
    358376    pop     ds
    359     or      dl, (1<<4)  ; Writes need A4 set
    360 ALIGN JUMP_ALIGN
    361 .ReadNextQword:
    362     lodsw               ; Load 1st WORD from [DS:SI]
    363     out     dx, ax      ; Write 1st WORD
    364     lodsw
    365     out     dx, ax      ; 2nd
    366     lodsw
    367     out     dx, ax      ; 3rd
    368     lodsw
    369     out     dx, ax      ; 4th
    370     loop    .ReadNextQword
     377ALIGN JUMP_ALIGN
     378.WriteNextDword:
     379    lodsb               ; Load 1st BYTE from [DS:SI]
     380    out     dx, al      ; Write 1st BYTE
     381    lodsb
     382    out     dx, al
     383
     384    lodsb
     385    out     dx, al
     386    lodsb
     387    out     dx, al
     388    loop    .WriteNextDword
    371389    pop     ds
    372390    ret
     
    404422%ifdef MODULE_8BIT_IDE
    405423        dw      0                           ; 0, DEVICE_8BIT_JRIDE_ISA
     424        dw      ReadBlockFromXTCF           ; 1, DEVICE_8BIT_XTCF
    406425    %ifdef USE_186
    407         dw      ReadBlockFrom16bitDataPort  ; 1, DEVICE_FAST_XTIDE
    408426        dw      ReadBlockFrom16bitDataPort  ; 2, DEVICE_8BIT_XTIDE_REV2
    409427    %else
    410         dw      ReadBlockFromXtideRev2      ; 1, DEVICE_FAST_XTIDE
    411428        dw      ReadBlockFromXtideRev2      ; 2, DEVICE_8BIT_XTIDE_REV2
    412429    %endif
     
    425442%ifdef MODULE_8BIT_IDE
    426443        dw      0                           ; 0, DEVICE_8BIT_JRIDE_ISA
    427         dw      WriteBlockToFastXtide       ; 1, DEVICE_FAST_XTIDE
     444        dw      WriteBlockToXTCF            ; 1, DEVICE_8BIT_XTCF
    428445        dw      WriteBlockToXtideRev2       ; 2, DEVICE_XTIDE_REV2
    429446        dw      WriteBlockToXtideRev1       ; 3, DEVICE_XTIDE_REV1
Note: See TracChangeset for help on using the changeset viewer.