Changeset 364 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/Boot/BootMenuInfo.asm


Ignore:
Timestamp:
Mar 27, 2012, 4:21:58 PM (12 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.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/XTIDE_Universal_BIOS/Src/Boot/BootMenuInfo.asm

    r363 r364  
    1717;       ES:BX:  Ptr to BOOTMENUINFO (if successful)
    1818;   Corrupts registers:
    19 ;       AX, CX, DX, DI
     19;       AX, BX, CX, DX, DI
    2020;--------------------------------------------------------------------
    2121BootMenuInfo_CreateForHardDisk:
    2222    call    BootMenuInfo_ConvertDPTtoBX         ; ES:BX now points to new BOOTMENUINFO
    23     push    ds                                  ; Preserve RAMVARS...
    24     push    si                                  ; ...and SI
    25 
    26     push    es                                  ; ES to be copied to DS
    27 
    28 %ifdef MODULE_ADVANCED_ATA
    29     ; Copy DPT_ADVANCED_ATA to BOOTMENUINFO to keep DPTs small.
    30     ; DPT_ADVANCED_ATA has variables that are only needed during initialization.
    31     mov     ax, [di+DPT_ADVANCED_ATA.wIdeBasePort]
    32     mov     [es:bx+BOOTMENUINFO.wIdeBasePort], ax
    33     mov     dx, [di+DPT_ADVANCED_ATA.wMinPioActiveTimeNs]
    34     mov     [es:bx+BOOTMENUINFO.wMinPioActiveTimeNs], dx
    35 
    36     mov     ax, [di+DPT_ADVANCED_ATA.wMinPioRecoveryTimeNs]
    37     mov     cx, [di+DPT_ADVANCED_ATA.wControllerID]
    38     mov     dx, [di+DPT_ADVANCED_ATA.wControllerBasePort]
    39     pop     ds                                  ; ES copied to DS
    40     mov     [bx+BOOTMENUINFO.wMinPioRecoveryTimeNs], ax
    41     mov     [bx+BOOTMENUINFO.wControllerID], cx
    42     mov     [bx+BOOTMENUINFO.wControllerBasePort], dx
    43 
    44 %else
    45     pop     ds                                  ; ES copied to DS
    46 %endif
    4723
    4824    ; Store Drive Name
     25    push    ds                                  ; Preserve RAMVARS
     26    push    si
     27
     28    push    es                                  ; ES copied to DS
     29    pop     ds
     30
    4931    add     si, BYTE ATA1.strModel              ; DS:SI now points drive name
    5032    lea     di, [bx+BOOTMENUINFO.szDrvName]     ; ES:DI now points to name destination
     
    6042    pop     si
    6143    pop     ds
     44       
    6245    ret
    6346
     
    7255;       CX
    7356;--------------------------------------------------------------------
     57ALIGN JUMP_ALIGN
    7458BootMenuInfo_GetTotalSectorCount:
    7559    test    BYTE [di+DPT.bFlagsLow], FLG_DRVNHEAD_LBA
     
    117101    xchg    ax, bx
    118102    pop     ax
    119     ret        
     103    ret
Note: See TracChangeset for help on using the changeset viewer.