Changeset 596 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS


Ignore:
Timestamp:
Jul 10, 2018, 1:20:11 AM (6 years ago)
Author:
Krister Nordvall
Message:

Changes:

  • Made changes to HotkeyBar.asm to give the Boot Menu and Hotkey Bar a more consistent look. It will probably seem a bit strange at first to people used to the classic theme.
  • Added the missing parts of USE_NEC_V that should have been committed with the rest in r593.
  • Removed DEFINES_ALL_FEATURES from the BIOS makefile. It didn't work anymore and never really made sense anyway. Added all the official builds to 'make unused' instead which actually uncovered some unused code in the Tiny build.
  • XTIDECFG will no longer load color themes from unrecognized versions of the BIOS.
  • Other fixes in comments and some minor optimizations.
Location:
trunk/XTIDE_Universal_BIOS
Files:
14 edited

Legend:

Unmodified
Added
Removed
  • trunk/XTIDE_Universal_BIOS/Inc/BootVars.inc

    r595 r596  
    4343    .wFddAndHddLetters:
    4444    .bFddLetter         resb    1       ; Floppy Drive letter hotkey (upper case)
     45    .wHddLetterAndFlags:
    4546    .bHddLetter         resb    1       ; Hard Drive letter hotkey (upper case). Must be after .bFddLetter!
    4647    .bFlags             resb    1       ; Must be just after .bHddLetter!  (dependency in Hotkeybar.asm)
  • trunk/XTIDE_Universal_BIOS/Src/Device/IDE/IdeCommand.asm

    r592 r596  
    3131;       AL, BX, CX, DX
    3232;--------------------------------------------------------------------
    33 IdeCommand_ResetMasterAndSlaveController:
     33IdeCommand_ResetMasterAndSlaveController:   ; Unused entrypoint OK
    3434    ; HSR0: Set_SRST
    3535; Used to be:
     
    8181;       AL, BX, CX, DX, SI, DI, ES
    8282;--------------------------------------------------------------------
    83 IdeCommand_IdentifyDeviceToBufferInESSIwithDriveSelectByteInBH:
     83IdeCommand_IdentifyDeviceToBufferInESSIwithDriveSelectByteInBH:     ; Unused entrypoint OK
    8484    ; Create fake DPT to be able to use Device.asm functions
    8585    call    FindDPT_ForNewDriveToDSDI
     
    145145;--------------------------------------------------------------------
    146146ALIGN JUMP_ALIGN
    147 IdeCommand_OutputWithParameters:
     147IdeCommand_OutputWithParameters:    ; Unused entrypoint OK
    148148    push    bx                      ; Store status register bits to poll
    149149
  • trunk/XTIDE_Universal_BIOS/Src/Device/IDE/IdeDPT.asm

    r592 r596  
    3232;       AX, BX, CX, DX
    3333;--------------------------------------------------------------------
    34 IdeDPT_Finalize:
     34IdeDPT_Finalize:    ; Unused entrypoint OK
    3535
    3636%ifdef MODULE_POWER_MANAGEMENT
  • trunk/XTIDE_Universal_BIOS/Src/Device/Idepack.asm

    r542 r596  
    114114    mov     [bp+IDEPACK.wLbaMiddleAndHigh], cx
    115115    pop     bx
     116    ; Fall to GetDeviceControlByteToIdepackAndStartTransfer
    116117
    117118GetDeviceControlByteToIdepackAndStartTransfer:
  • trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h.asm

    r592 r596  
    339339Int13h_CallPreviousInt13hHandler:
    340340    pushf                       ; Simulate INT by pushing flags
    341     call far [RAMVARS.fpOldI13h]
     341    call    FAR [RAMVARS.fpOldI13h]
    342342    ret
    343343
  • trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h/Tools/Prepare.asm

    r568 r596  
    132132    ret     ; Continue with transfer
    133133
     134%ifdef MODULE_EBIOS
    134135InvalidDAP:
     136Prepare_ReturnFromInt13hWithInvalidFunctionError:
     137%endif
    135138InvalidNumberOfSectorsRequested:
    136 Prepare_ReturnFromInt13hWithInvalidFunctionError:
    137139    mov     ah, RET_HD_INVALID
    138140    SKIP2B  f
    139141CannotAlignPointerProperly:
    140142    mov     ah, RET_HD_BOUNDARY
     143%ifdef MODULE_EBIOS
    141144ZeroSectorsRequestedSoNoErrors:
     145%endif
    142146    jmp     Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH
    143147
     
    161165%endif
    162166
     167%ifdef MODULE_EBIOS
    163168g_rgbVerifyCommandLookup:
    164169    db      COMMAND_VERIFY_SECTORS
    165170    db      COMMAND_VERIFY_SECTORS_EXT
    166171    db      COMMAND_VERIFY_SECTORS
    167 %ifdef MODULE_EBIOS
    168172    db      COMMAND_VERIFY_SECTORS_EXT
    169173%endif
  • trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13hMFMcompatibility.asm

    r594 r596  
    11; Project name  :   XTIDE Universal BIOS
    22; Description   :   Int 13h handler that is used by MODULE_MFM_COMPATIBILITY.
    3 ;                   It is placed between XTUB Int 13h hander and system INT 13h hander
    4 ;                   to hide XTUB from MFM controllers whose BIOS assumes they handler
     3;                   It is placed between XUB Int 13h handler and system INT 13h handler
     4;                   to hide XUB from MFM controllers whose BIOS assumes they handle
    55;                   all hard drives on the system.
    66
     
    2828; Int 13h software interrupt handler for MFM compatibility.
    2929;
    30 ; Some MDM controllers require that BDA drive count is what they have set.
     30; Some MFM controllers require that BDA drive count is what they have set.
    3131; The purpose for this handler is to restore BDA drive count to what MFM controller
    3232; expects and then call MFM controller INT 13h.
     
    6464
    6565    pushf   ; Push flags to simulate INT
    66     call far [bp-6]
     66    call    FAR [bp-6]
    6767
    6868    ; Now we can restore BDA drive count
  • trunk/XTIDE_Universal_BIOS/Src/Handlers/Int19h.asm

    r595 r596  
    229229    mov     gs, ax
    230230%endif
    231     jnc     SHORT .romboot
     231    jnc     SHORT .RomBoot
    232232
    233233; jump to boot sector
     
    237237
    238238; Boot by calling INT 18h (ROM Basic of ROM DOS)
    239 .romboot:
     239.RomBoot:
    240240    int     BIOS_BOOT_FAILURE_INTERRUPT_18h ; Never returns
  • trunk/XTIDE_Universal_BIOS/Src/Initialization/AdvancedAta/AdvAtaInit.asm

    r593 r596  
    3737AdvAtaInit_DetectControllerForIdeBaseInBX:
    3838    ; Detect if system has PCI bus. If it does, we can skip VLB detection. This is
    39     ; good thing since detecting Vision QD6850 is dangerous since Intel PIIX4 south bridge
     39    ; good thing since detecting Vision QD6580 is dangerous since Intel PIIX4 south bridge
    4040    ; mirrors Interrupt Controller registers from Axh to Bxh. This can lead to faulty
    41     ; detection of QD6850 that will eventually crash the system when ports are written.
     41    ; detection of QD6580 that will eventually crash the system when ports are written.
    4242
    4343    ; We should save the 32-bit registers but we don't since system BIOS has stored
  • trunk/XTIDE_Universal_BIOS/Src/Initialization/AdvancedAta/Vision.asm

    r593 r596  
    194194    ; Calculate Recovery Time value for QD65xx IDE Timing Register
    195195    xchg    ax, cx
    196     eMOVZX  cx, BYTE [cs:bx+.rgbToSubtractFromCycleTimeBasedOnPIOmode]
    197     sub     ax, cx
     196    mov     bl, [cs:bx+.rgbToSubtractFromCycleTimeBasedOnPIOmode]
     197    sub     ax, bx
    198198    mov     bx, bp                      ; Active Time value now in BL
    199199    mov     bp, QD65xx_MAX_RECOVERY_TIME_CLOCKS | (QD65xx_MIN_RECOVERY_TIME_CLOCKS << 8)
  • trunk/XTIDE_Universal_BIOS/Src/Initialization/DetectDrives.asm

    r594 r596  
    9999; Primary reason is to support dynamic overlay feature in the future. Second reason
    100100; is a hack to get Windows 95 load proper IDE drivers.
    101 ; 
     101;
    102102; The Windows hack has two parts. First part is to try to alter CMOS address 12h as that
    103103; is what Windows 95 driver reads to detect IDE drives. Altering is not possible on all
    104 ; systems since CMOS has a checksum but it's location is not standardized. We will first
     104; systems since CMOS has a checksum but its location is not standardized. We will first
    105105; try to detect valid checksum. If it succeeds, then it is safe to assume this system
    106106; has compatible CMOS and we can alter it.
     
    117117        call    CMOS_Verify10hTo2Dh             ; Can we modify CMOS?
    118118        jnz     SHORT .ClearBdaDriveCount       ; Unsupported BIOS, use plan B
    119    
     119
    120120        ; Now we can alter CMOS location 12h
    121121        mov     dl, HARD_DISK_TYPES
  • trunk/XTIDE_Universal_BIOS/Src/Initialization/Interrupts.asm

    r594 r596  
    6565    mov     ax, [es:BIOS_DISK_INTERRUPT_13h*4]  ; Load old INT 13h offset
    6666    mov     [RAMVARS.fpMFMint13h], ax           ; Store old INT 13h offset
    67    
     67
    6868    mov     [RAMVARS.fpOldI13h+2], cs
    69     mov     WORD [RAMVARS.fpOldI13h], Int13hMFMcompatibilityHandler 
     69    mov     WORD [RAMVARS.fpOldI13h], Int13hMFMcompatibilityHandler
    7070%else
    7171    mov     ax, [es:BIOS_DISK_INTERRUPT_13h*4+2]; Load old INT 13h segment
     
    252252    xchg    cx, ax              ; IRQ index to CL
    253253    in      al, dx              ; Read Interrupt Mask Register
     254%ifdef USE_NEC_V
     255    eCLR1   al, cl              ; Clear wanted bit
     256%else
    254257    mov     ch, ~1              ; Load bit mask to be rotated
    255258    rol     ch, cl              ; Rotate mask to correct position for clearing
    256259    and     al, ch              ; Clear wanted bit
     260%endif
    257261    out     dx, al              ; Write modified Interrupt Mask Register
    258262    pop     cx
  • trunk/XTIDE_Universal_BIOS/Src/Menus/HotkeyBar.asm

    r593 r596  
    7878    ; Clear CH if floppy drive is selected for boot
    7979    mov     ch, [es:BOOTVARS.hotkeyVars+HOTKEYVARS.bFlags]
    80     ;and        ch, FLG_HOTKEY_HD_FIRST     ; Needed if more flags are added
     80;   and     ch, FLG_HOTKEY_HD_FIRST     ; Needed if more flags are added
    8181    call    FormatDriveHotkeyString
    8282
     
    9696    call    BootVars_GetLetterForFirstHardDriveToAX
    9797    mov     ah, ANGLE_QUOTE_RIGHT
    98     mov     cx, [es:BOOTVARS.hotkeyVars+HOTKEYVARS.bHddLetter]  ; Letter to CL, flags to CH
    99     ;and        ch, FLG_HOTKEY_HD_FIRST     ; Needed if more flags are added
     98    mov     cx, [es:BOOTVARS.hotkeyVars+HOTKEYVARS.wHddLetterAndFlags]  ; Letter to CL, flags to CH
     99;   and     ch, FLG_HOTKEY_HD_FIRST     ; Needed if more flags are added
    100100    xor     ch, FLG_HOTKEY_HD_FIRST     ; Clear CH if HD is selected for boot, set otherwise
    101101    mov     di, g_szHDD
     
    234234
    235235GetSelectedHotkeyDescriptionAttributeToDX:
    236     mov     si, ATTRIBUTE_CHARS.cHurryTimeout       ; Selected hotkey
     236    mov     si, ATTRIBUTE_CHARS.cHighlightedItem    ; Selected hotkey
    237237    je      SHORT GetDescriptionAttributeToDX       ; From compare with bScancode above and from FormatDriveHotkeyString
    238238
    239239GetNonSelectedHotkeyDescriptionAttributeToDX:
    240     mov     si, ATTRIBUTE_CHARS.cHighlightedItem    ; Unselected hotkey
     240    mov     si, ATTRIBUTE_CHARS.cItem               ; Unselected hotkey
    241241
    242242    ; Display Library should not be called like this
  • trunk/XTIDE_Universal_BIOS/makefile

    r595 r596  
    122122DEFINES_386_LARGE = $(DEFINES_AT_LARGE) USE_386 MODULE_ADVANCED_ATA
    123123
    124 DEFINES_ALL_FEATURES = MODULE_8BIT_IDE MODULE_8BIT_IDE_ADVANCED MODULE_ADVANCED_ATA MODULE_EBIOS MODULE_BOOT_MENU MODULE_HOTKEYS MODULE_IRQ MODULE_SERIAL MODULE_SERIAL_FLOPPY MODULE_STRINGS_COMPRESSED MODULE_POWER_MANAGEMENT MODULE_COMPATIBLE_TABLES
    125 DEFINES_ALL_FEATURES += ELIMINATE_CGA_SNOW RELOCATE_INT13H_STACK RESERVE_DIAGNOSTIC_CYLINDER MODULE_WIN95_CMOS_HACK MODULE_MFM_COMPATIBILITY
    126 
    127124
    128125###################
     
    146143DEFS_386 = $(DEFINES_386:%=-D%) -DBIOS_SIZE=$(BIOS_SIZE_SMALL)
    147144DEFS_386_LARGE = $(DEFINES_386_LARGE:%=-D%) -DBIOS_SIZE=$(BIOS_SIZE_LARGE)
    148 DEFS_ALL_FEATURES = $(DEFINES_ALL_FEATURES:%=-D%)
    149145
    150146# Add -I in front of all header directories
     
    249245
    250246unused:
    251     @echo "All Features"
    252     @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_ALL_FEATURES) $(DEFS_XT) $(DEFS_XT_PLUS) $(DEFS_AT) $(DEFS_XT_LARGE) $(DEFS_XTPLUS_LARGE) $(DEFS_AT_LARGE) $(DEFS_XT_TINY) $(DEFS_386_8K) -o"$(TARGET)_unused.asm" -l"$(TARGET)_unused.lst"
    253     @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_ALL_FEATURES) $(DEFS_XT) $(DEFS_XT_PLUS) $(DEFS_AT) $(DEFS_XT_LARGE) $(DEFS_XTPLUS_LARGE) $(DEFS_AT_LARGE) $(DEFS_XT_TINY) $(DEFS_386_8K) -o"$(TARGET)_unused.asm" -E -DCHECK_FOR_UNUSED_ENTRYPOINTS
    254     @perl ..\Tools\unused.pl $(TARGET)_unused.lst $(TARGET)_unused.asm
     247    @echo "XT Tiny"
     248    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_XT_TINY) -o"$(TARGET)_unused_tiny.asm" -l"$(TARGET)_unused_tiny.lst"
     249    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_XT_TINY) -o"$(TARGET)_unused_tiny.asm" -E -DCHECK_FOR_UNUSED_ENTRYPOINTS
     250    @perl ..\Tools\unused.pl $(TARGET)_unused_tiny.lst $(TARGET)_unused_tiny.asm
    255251    @echo "XT Small"
    256252    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_XT) -o"$(TARGET)_unused_xt.asm" -l"$(TARGET)_unused_xt.lst"
     
    261257    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_XT_LARGE) -o"$(TARGET)_unused_xtl.asm" -E -DCHECK_FOR_UNUSED_ENTRYPOINTS
    262258    @perl ..\Tools\unused.pl $(TARGET)_unused_xtl.lst $(TARGET)_unused_xtl.asm
     259    @echo "XT Plus Small"
     260    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_XTPLUS) -o"$(TARGET)_unused_xtp.asm" -l"$(TARGET)_unused_xtp.lst"
     261    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_XTPLUS) -o"$(TARGET)_unused_xtp.asm" -E -DCHECK_FOR_UNUSED_ENTRYPOINTS
     262    @perl ..\Tools\unused.pl $(TARGET)_unused_xtp.lst $(TARGET)_unused_xtp.asm
     263    @echo "XT Plus Large"
     264    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_XTPLUS_LARGE) -o"$(TARGET)_unused_xtpl.asm" -l"$(TARGET)_unused_xtpl.lst"
     265    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_XTPLUS_LARGE) -o"$(TARGET)_unused_xtpl.asm" -E -DCHECK_FOR_UNUSED_ENTRYPOINTS
     266    @perl ..\Tools\unused.pl $(TARGET)_unused_xtpl.lst $(TARGET)_unused_xtpl.asm
    263267    @echo "AT Small"
    264268    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_AT) -o"$(TARGET)_unused_at.asm" -l"$(TARGET)_unused_at.lst"
     
    269273    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_AT_LARGE) -o"$(TARGET)_unused_atl.asm" -E -DCHECK_FOR_UNUSED_ENTRYPOINTS
    270274    @perl ..\Tools\unused.pl $(TARGET)_unused_atl.lst $(TARGET)_unused_atl.asm
    271 
    272 
     275    @echo "386 Small"
     276    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_386) -o"$(TARGET)_unused_386.asm" -l"$(TARGET)_unused_386.lst"
     277    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_386) -o"$(TARGET)_unused_386.asm" -E -DCHECK_FOR_UNUSED_ENTRYPOINTS
     278    @perl ..\Tools\unused.pl $(TARGET)_unused_386.lst $(TARGET)_unused_386.asm
     279    @echo "386 Large"
     280    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_386_LARGE) -o"$(TARGET)_unused_386l.asm" -l"$(TARGET)_unused_386l.lst"
     281    @$(AS) "$(SRC_ASM)" $(ASFLAGS) $(DEFS_386_LARGE) -o"$(TARGET)_unused_386l.asm" -E -DCHECK_FOR_UNUSED_ENTRYPOINTS
     282    @perl ..\Tools\unused.pl $(TARGET)_unused_386l.lst $(TARGET)_unused_386l.asm
     283
Note: See TracChangeset for help on using the changeset viewer.