Ignore:
Timestamp:
May 15, 2021, 8:27:11 PM (3 years ago)
Author:
krille_n_
Message:

Changes:

  • RESERVE_DIAGNOSTIC_CYLINDER has been completely removed as it wasted hard drive space, caused a compatibility problem with 32-bit disk access drivers under Windows 3.x and most importantly, it was in fact not needed since the same thing can be accomplished using the "User specified CHS" feature in XTIDECFG which is better because that applies only to that specific drive instead of all drives under XUB control.
  • In BIOS builds containing MODULE_EBIOS (i.e. all official builds except the Tiny build), drives with a cylinder count less than or equal to 1024 had CHS translation applied to them unnecessarily if CHS translation method was set to Auto (which is the default). This bug has been present for a long time and, as a side effect, made RESERVE_DIAGNOSTIC_CYLINDER useless since the idea behind that was to provide compatibility with other old BIOSes using NORMAL addressing mode. WARNING! With this bug now being fixed, upgrading to this revision of the BIOS will require repartitioning and reformatting any drives affected by this (BIOSDRVS.COM can be helpful in determining which drives are affected).
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs/AtaGeometry.asm

    r592 r606  
    7474;       BH:     Number of L-CHS sectors per track (1...63)
    7575;       CX:     Number of bits shifted (0...3)
    76 ;       DL:     CHS Translate Mode
    77 ;   Corrupts registers:
    78 ;       DH
     76;       DX:     CHS Translate Mode
     77;   Corrupts registers:
     78;       Nothing
    7979;--------------------------------------------------------------------
    8080AtaGeometry_GetLCHStoAXBLBHfromAtaInfoInESSIwithTranslateModeInDX:
     
    100100    cmp     ax, 8192
    101101    jbe     SHORT ConvertPCHfromAXBLtoEnhancedCHinAXBL
     102%else
     103    ; Check if the drive is within the limits of NORMAL addressing.
     104    ; If it is, then no CHS translation is necessary.
     105    cmp     ax, MAX_LCHS_CYLINDERS
     106    jbe     SHORT ConvertPCHfromAXBLtoEnhancedCHinAXBL
    102107%endif
    103108
     
    161166;       BH:     Number of sectors per track (always 63)
    162167;       CX:     Number of bits shifted (0)
    163 ;       DL:     TRANSLATEMODE_ASSISTED_LBA
    164 ;   Corrupts registers:
    165 ;       DH
     168;       DX:     TRANSLATEMODE_ASSISTED_LBA
     169;   Corrupts registers:
     170;       Nothing
    166171;--------------------------------------------------------------------
    167172ConvertChsSectorCountFromDXAXtoLbaAssistedLCHSinAXBLBH:
     
    213218    xchg    bh, cl                      ; Sectors per Track to BH, zero to CL (CX)
    214219    mov     dl, TRANSLATEMODE_ASSISTED_LBA
     220    ; All combinations of value CH from 1 to 262128 divided by number of heads
     221    ; (16/32/64/128/255) has been verified to return with DH cleared.
    215222ReturnLCHSinAXBLBH:
    216223    ret
Note: See TracChangeset for help on using the changeset viewer.