- Timestamp:
- Apr 19, 2012, 3:08:06 PM (13 years ago)
- google:author:
- aitotat@gmail.com
- Location:
- trunk/XTIDE_Universal_BIOS
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/XTIDE_Universal_BIOS/Inc/ModuleDependency.inc
r397 r398 26 26 %endif 27 27 28 %ifdef MODULE_SERIAL_FLOPPY 29 %ifndef MODULE_SERIAL 30 %define MODULE_SERIAL 31 %endif 32 %endif 33 28 34 29 35 30 36 ; Include module specific .INC files 37 %ifdef MODULE_ADVANCED_ATA 38 %include "Vision.inc" ; For QDI Vision QD65xx VLB IDE Controllers 39 %endif 40 31 41 %ifdef MODULE_EBIOS 32 42 %include "EBIOS.inc" ; Equates for EBIOS functions … … 40 50 %endif 41 51 42 %ifdef MODULE_ ADVANCED_ATA43 %include " Vision.inc" ; For QDI Vision QD65xx VLB IDE Controllers52 %ifdef MODULE_IRQ 53 %include "IntController.inc" 44 54 %endif 55 45 56 46 57 … … 70 81 %endif 71 82 83 %ifdef MODULE_IRQ 84 MAIN_FLG_MODULE_IRQ EQU FLG_ROMVARS_MODULE_IRQ 85 %else 86 MAIN_FLG_MODULE_IRQ EQU 0 87 %endif 88 72 89 %ifdef MODULE_JRIDE 73 90 MAIN_FLG_MODULE_JRIDE EQU FLG_ROMVARS_MODULE_JRIDE … … 94 111 %endif 95 112 96 MASK_ROMVARS_INCLUDED_MODULES EQU MAIN_FLG_MODULE_ADVANCED_ATA | MAIN_FLG_MODULE_BOOT_MENU | MAIN_FLG_MODULE_EBIOS | MAIN_FLG_MODULE_HOTKEYS | MAIN_FLG_MODULE_ JRIDE | MAIN_FLG_MODULE_SERIAL | MAIN_FLG_MODULE_SERIAL_FLOPPY | MAIN_FLG_MODULE_STRINGS_COMPRESSED113 MASK_ROMVARS_INCLUDED_MODULES EQU MAIN_FLG_MODULE_ADVANCED_ATA | MAIN_FLG_MODULE_BOOT_MENU | MAIN_FLG_MODULE_EBIOS | MAIN_FLG_MODULE_HOTKEYS | MAIN_FLG_MODULE_IRQ | MAIN_FLG_MODULE_JRIDE | MAIN_FLG_MODULE_SERIAL | MAIN_FLG_MODULE_SERIAL_FLOPPY | MAIN_FLG_MODULE_STRINGS_COMPRESSED -
trunk/XTIDE_Universal_BIOS/Inc/RomVars.inc
r397 r398 70 70 ; (Conveniently, this is 8, a fact we exploit when testing the bit) 71 71 72 FLG_ROMVARS_MODULE_ADVANCED_ATA EQU (1<<8) ; Here in case the configuration needs to know functionality is present 73 FLG_ROMVARS_MODULE_BOOT_MENU EQU (1<<9) ; Here in case the configuration needs to know functionality is present 74 FLG_ROMVARS_MODULE_EBIOS EQU (1<<10) ; Here in case the configuration needs to know functionality is present 75 FLG_ROMVARS_MODULE_HOTKEYS EQU (1<<11) ; Here in case the configuration needs to know functionality is present 72 FLG_ROMVARS_MODULE_ADVANCED_ATA EQU (1<<7) ; Here in case the configuration needs to know functionality is present 73 FLG_ROMVARS_MODULE_BOOT_MENU EQU (1<<8) ; Here in case the configuration needs to know functionality is present 74 FLG_ROMVARS_MODULE_EBIOS EQU (1<<9) ; Here in case the configuration needs to know functionality is present 75 FLG_ROMVARS_MODULE_HOTKEYS EQU (1<<10) ; Here in case the configuration needs to know functionality is present 76 FLG_ROMVARS_MODULE_IRQ EQU (1<<11) ; Here in case the configuration needs to know functionality is present 76 77 FLG_ROMVARS_MODULE_JRIDE EQU (1<<12) ; Here in case the configuration needs to know functionality is present 77 78 FLG_ROMVARS_MODULE_SERIAL EQU (1<<13) ; Here in case the configuration needs to know functionality is present … … 118 119 ; 119 120 DEVICE_XTIDE_DEFAULT_PORT EQU 300h 120 DEVICE_XTIDE_DEFAULT_PORTCTRL EQU 308h 121 DEVICE_ATA_DEFAULT_PORT EQU 1F0h 122 DEVICE_ATA_DEFAULT_PORTCTRL EQU 3F0h 123 DEVICE_ATA_DEFAULT_SECONDARY_PORT EQU 170h 124 DEVICE_ATA_DEFAULT_SECONDARY_PORTCTRL EQU 370h 121 DEVICE_XTIDE_DEFAULT_PORTCTRL EQU DEVICE_XTIDE_DEFAULT_PORT + 8h 122 123 DEVICE_ATA_PRIMARY_PORT EQU 1F0h 124 DEVICE_ATA_PRIMARY_PORTCTRL EQU DEVICE_ATA_PRIMARY_PORT + 200h 125 126 DEVICE_ATA_SECONDARY_PORT EQU 170h 127 DEVICE_ATA_SECONDARY_PORTCTRL EQU DEVICE_ATA_SECONDARY_PORT + 200h 128 129 DEVICE_ATA_TERTIARY_PORT EQU 1E8h 130 DEVICE_ATA_TERTIARY_PORTCTRL EQU DEVICE_ATA_TERTIARY_PORT + 200h 131 132 DEVICE_ATA_QUATERNARY_PORT EQU 168h 133 DEVICE_ATA_QUATERNARY_PORTCTRL EQU DEVICE_ATA_QUATERNARY_PORT + 200h 134 125 135 126 136 ; Device types for IDEVARS.bDevice -
trunk/XTIDE_Universal_BIOS/Src/Device/IDE/IdeWait.asm
r376 r398 55 55 IDEDEVICE%+Wait_IRQorStatusFlagInBLwithTimeoutInBH: 56 56 %ifdef ASSEMBLE_SHARED_IDE_DEVICE_FUNCTIONS ; JR-IDE/ISA does not support IRQ 57 call IdeIrq_WaitForIRQ 57 %ifdef MODULE_IRQ 58 call IdeIrq_WaitForIRQ 59 %endif 58 60 %endif 59 61 ; Always fall to IdeWait_PollStatusFlagInBLwithTimeoutInBH for error processing -
trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h/AHDh_HReset.asm
r376 r398 62 62 push di 63 63 64 %ifdef MODULE_IRQ 64 65 call Interrupts_UnmaskInterruptControllerForDriveInDSDI 66 %endif 65 67 call Device_ResetMasterAndSlaveController 66 68 ;jc SHORT .ReturnError ; CF would be set if slave drive present without master -
trunk/XTIDE_Universal_BIOS/Src/Handlers/Int19h.asm
r397 r398 104 104 .DoNotDisplayBootMenu: 105 105 %endif 106 %endif107 106 108 107 ; Check if ROM boot (INT 18h) wanted 109 %ifdef MODULE_HOTKEYS110 108 cmp BYTE [es:BOOTVARS.hotkeyVars+HOTKEYVARS.bScancode], ROM_BOOT_HOTKEY_SCANCODE 111 109 je SHORT JumpToBootSector_or_RomBoot ; CF clear so ROM boot 112 %endif 113 114 ; Try to boot from Primary boot drive (00h by default) 115 %ifdef MODULE_HOTKEYS 110 111 ; Get Primary boot drive number to DL 116 112 call HotkeyBar_GetPrimaryBootDriveNumberToDL 117 113 %else 118 mov dl, [cs:ROMVARS.bBootDrv] 119 and dl, 80h ; Only 00h and 80h allowed when not using MODULE_HOTKEYS 120 %endif 114 call GetPrimaryBootDriveToDLwhenNotUsingModuleHotkeys 115 %endif ; MODULE_HOTKEYS 116 117 ; Try to boot from Primary boot drive (00h by default) 121 118 call TryToBootFromPrimaryOrSecondaryBootDevice 122 119 jc SHORT JumpToBootSector_or_RomBoot … … 126 123 call HotkeyBar_GetSecondaryBootDriveNumberToDL 127 124 %else 128 mov dl, [cs:ROMVARS.bBootDrv] 129 and dl, 80h 125 call GetPrimaryBootDriveToDLwhenNotUsingModuleHotkeys 130 126 xor dl, 80h 131 127 %endif … … 203 199 jmp BootSector_TryToLoadFromDriveDL 204 200 %endif 201 202 203 ;-------------------------------------------------------------------- 204 ; GetPrimaryBootDriveToDLwhenNotUsingModuleHotkeys 205 ; Parameters 206 ; Nothing 207 ; Returns: 208 ; DL: Drive to boot from (00h or 80h) 209 ; Corrupts registers: 210 ; Nothing 211 ;-------------------------------------------------------------------- 212 %ifndef MODULE_HOTKEYS 213 GetPrimaryBootDriveToDLwhenNotUsingModuleHotkeys: 214 mov dl, [cs:ROMVARS.bBootDrv] 215 and dl, 80h ; Only 00h and 80h allowed when not using MODULE_HOTKEYS 216 ret 217 %endif -
trunk/XTIDE_Universal_BIOS/Src/Initialization/AdvancedAta/Vision.asm
r392 r398 91 91 ; QD6580 always have Primary IDE at 1F0h 92 92 ; Secondary IDE at 170h can be enabled or disabled 93 cmp bx, DEVICE_ATA_ DEFAULT_PORT93 cmp bx, DEVICE_ATA_PRIMARY_PORT 94 94 je SHORT .ReturnResultInZF 95 95 … … 108 108 test al, FLG_QDCONFIG_PRIMARY_IDE 109 109 jz SHORT .CompareBXtoSecondaryIDE 110 cmp bx, DEVICE_ATA_ DEFAULT_PORT110 cmp bx, DEVICE_ATA_PRIMARY_PORT 111 111 ret 112 112 113 113 .CompareBXtoSecondaryIDE: 114 cmp bx, DEVICE_ATA_ DEFAULT_SECONDARY_PORT114 cmp bx, DEVICE_ATA_SECONDARY_PORT 115 115 .ReturnResultInZF: 116 116 ret … … 180 180 ; QD6580 always has Primary channel at 1F0h. Secondary channel at 170h can be Enabled or Disabled. 181 181 call AccessDPT_GetIdeBasePortToBX 182 cmp bx, DEVICE_ATA_ DEFAULT_PORT182 cmp bx, DEVICE_ATA_PRIMARY_PORT 183 183 je SHORT .CalculateTimingTicksForQD6580 ; Primary Channel so no need to modify DX 184 184 times 2 inc dx ; Secondary Channel IDE Timing Register -
trunk/XTIDE_Universal_BIOS/Src/Initialization/Interrupts.asm
r392 r398 67 67 mov al, BIOS_BOOT_LOADER_INTERRUPT_19h ; INT 19h interrupt vector offset 68 68 mov si, Int19hReset_Handler ; INT 19h handler to reboot the system 69 %ifndef MODULE_IRQ 70 ; Fall to Interrupts_InstallHandlerToVectorInALFromCSSI 71 %else 69 72 call Interrupts_InstallHandlerToVectorInALFromCSSI 70 73 ; Fall to .InitializeHardwareIrqHandlers … … 136 139 mov si, IdeIrq_InterruptServiceRoutineForIrqs2to7 137 140 ; Fall to Interrupts_InstallHandlerToVectorInALFromCSSI 141 %endif ; MODULE_IRQ 138 142 139 143 … … 158 162 159 163 164 %ifdef MODULE_IRQ 160 165 ;-------------------------------------------------------------------- 161 166 ; Interrupts_UnmaskInterruptControllerForDriveInDSDI … … 227 232 .Return: 228 233 ret 234 235 %endif ; MODULE_IRQ -
trunk/XTIDE_Universal_BIOS/Src/Main.asm
r397 r398 46 46 ; Included .inc files 47 47 %include "AssemblyLibrary.inc" ; Assembly Library. Must be included first! 48 %include "ModuleDependency.inc" ; Dependency checks for optional modules 48 49 %include "Version.inc" 49 %include "ModuleDependency.inc" ; Dependency checks for optional modules50 %include "IntController.inc" ; For Interrupt Controller equates51 50 %include "ATA_ID.inc" ; For ATA Drive Information structs 52 51 %include "IdeRegisters.inc" ; For ATA Registers, flags and commands … … 89 88 at ROMVARS.bIdleTimeout, db 0 ; Standby timer disabled by default 90 89 91 at ROMVARS.ideVars0+IDEVARS.wPort, dw DEVICE_ATA_ DEFAULT_PORT ; Controller Command Block base port92 at ROMVARS.ideVars0+IDEVARS.wPortCtrl, dw DEVICE_ATA_ DEFAULT_PORTCTRL ; Controller Control Block base port90 at ROMVARS.ideVars0+IDEVARS.wPort, dw DEVICE_ATA_PRIMARY_PORT ; Controller Command Block base port 91 at ROMVARS.ideVars0+IDEVARS.wPortCtrl, dw DEVICE_ATA_PRIMARY_PORTCTRL ; Controller Control Block base port 93 92 at ROMVARS.ideVars0+IDEVARS.bDevice, db DEVICE_16BIT_ATA 94 93 at ROMVARS.ideVars0+IDEVARS.bIRQ, db 0 … … 96 95 at ROMVARS.ideVars0+IDEVARS.drvParamsSlave+DRVPARAMS.wFlags, db DISABLE_WRITE_CACHE | FLG_DRVPARAMS_BLOCKMODE 97 96 98 at ROMVARS.ideVars1+IDEVARS.wPort, dw DEVICE_ATA_ DEFAULT_SECONDARY_PORT99 at ROMVARS.ideVars1+IDEVARS.wPortCtrl, dw DEVICE_ATA_ DEFAULT_SECONDARY_PORTCTRL97 at ROMVARS.ideVars1+IDEVARS.wPort, dw DEVICE_ATA_SECONDARY_PORT 98 at ROMVARS.ideVars1+IDEVARS.wPortCtrl, dw DEVICE_ATA_SECONDARY_PORTCTRL 100 99 at ROMVARS.ideVars1+IDEVARS.bDevice, db DEVICE_16BIT_ATA 101 100 at ROMVARS.ideVars1+IDEVARS.bIRQ, db 0 … … 103 102 at ROMVARS.ideVars1+IDEVARS.drvParamsSlave+DRVPARAMS.wFlags, db DISABLE_WRITE_CACHE | FLG_DRVPARAMS_BLOCKMODE 104 103 105 at ROMVARS.ideVars2+IDEVARS.wPort, dw 1E8h106 at ROMVARS.ideVars2+IDEVARS.wPortCtrl, dw 3E8h104 at ROMVARS.ideVars2+IDEVARS.wPort, dw DEVICE_ATA_TERTIARY_PORT 105 at ROMVARS.ideVars2+IDEVARS.wPortCtrl, dw DEVICE_ATA_TERTIARY_PORTCTRL 107 106 at ROMVARS.ideVars2+IDEVARS.bDevice, db DEVICE_16BIT_ATA 108 107 at ROMVARS.ideVars2+IDEVARS.bIRQ, db 0 … … 110 109 at ROMVARS.ideVars2+IDEVARS.drvParamsSlave+DRVPARAMS.wFlags, db DISABLE_WRITE_CACHE | FLG_DRVPARAMS_BLOCKMODE 111 110 112 at ROMVARS.ideVars3+IDEVARS.wPort, dw 168h113 at ROMVARS.ideVars3+IDEVARS.wPortCtrl, dw 368h111 at ROMVARS.ideVars3+IDEVARS.wPort, dw DEVICE_ATA_QUATERNARY_PORT 112 at ROMVARS.ideVars3+IDEVARS.wPortCtrl, dw DEVICE_ATA_QUATERNARY_PORTCTRL 114 113 at ROMVARS.ideVars3+IDEVARS.bDevice, db DEVICE_16BIT_ATA 115 114 at ROMVARS.ideVars3+IDEVARS.bIRQ, db 0 … … 232 231 %include "IdeDPT.asm" 233 232 %include "IdeIO.asm" 233 %ifdef MODULE_IRQ 234 234 %include "IdeIrq.asm" 235 %endif 235 236 %undef IDEDEVICE 236 237 %undef ASSEMBLE_SHARED_IDE_DEVICE_FUNCTIONS -
trunk/XTIDE_Universal_BIOS/makefile
r397 r398 19 19 # MODULE_EBIOS Enhanced functions for accessing drives over 8.4 GB # 20 20 # MODULE_HOTKEYS Hotkey Bar to boot from any drive # 21 # MODULE_IRQ IDE IRQ support # 21 22 # MODULE_JRIDE Support for JR-IDE/ISA # 22 23 # MODULE_SERIAL Virtual hard disks using serial port # … … 95 96 DEFINES_XT = $(DEFINES_COMMON) ELIMINATE_CGA_SNOW MODULE_JRIDE MODULE_SERIAL MODULE_SERIAL_FLOPPY 96 97 DEFINES_XTPLUS = $(DEFINES_COMMON) $(DEFINES_XT) USE_186 97 DEFINES_AT = $(DEFINES_COMMON) USE_AT USE_286 MODULE_ SERIAL MODULE_SERIAL_FLOPPY MODULE_ADVANCED_ATA98 DEFINES_AT = $(DEFINES_COMMON) USE_AT USE_286 MODULE_IRQ MODULE_SERIAL MODULE_SERIAL_FLOPPY MODULE_ADVANCED_ATA 98 99 99 100 DEFINES_XT_LARGE = $(DEFINES_XT) $(DEFINES_COMMON_LARGE)
Note:
See TracChangeset
for help on using the changeset viewer.