Changeset 414 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src
- Timestamp:
- May 3, 2012, 12:56:04 PM (13 years ago)
- google:author:
- aitotat@gmail.com
- Location:
- trunk/XTIDE_Universal_BIOS/Src
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/XTIDE_Universal_BIOS/Src/Device/IDE/IdeIO.asm
r412 r414 33 33 ;-------------------------------------------------------------------- 34 34 IdeIO_OutputALtoIdeControlBlockRegisterInDL: 35 %ifdef MODULE_8BIT_IDE36 mov dh, [di+DPT_ATA.bDevice]37 %ifdef MODULE_JRIDE38 test dh, dh39 jnz SHORT .OutputToIoMappedIde40 41 add dx, JRIDE_CONTROL_BLOCK_REGISTER_WINDOW_OFFSET42 jmp SHORT OutputToJrIdeRegister43 .OutputToIoMappedIde:44 %endif ; MODULE_JRIDE45 %endif ; MODULE_8BIT_IDE35 %ifdef MODULE_8BIT_IDE 36 mov dh, [di+DPT_ATA.bDevice] 37 %ifdef MODULE_JRIDE 38 test dh, dh 39 jnz SHORT .OutputToIoMappedIde 40 41 add dx, JRIDE_CONTROL_BLOCK_REGISTER_WINDOW_OFFSET 42 jmp SHORT OutputToJrIdeRegister 43 .OutputToIoMappedIde: 44 %endif ; MODULE_JRIDE 45 %endif ; MODULE_8BIT_IDE 46 46 47 47 mov bl, IDEVARS.wPortCtrl … … 62 62 ALIGN JUMP_ALIGN 63 63 IdeIO_OutputALtoIdeRegisterInDL: 64 %ifdef MODULE_8BIT_IDE65 mov dh, [di+DPT_ATA.bDevice]66 %ifdef MODULE_JRIDE67 test dh, dh68 jnz SHORT OutputALtoIOmappedIdeRegisterInDL69 70 %if JRIDE_COMMAND_BLOCK_REGISTER_WINDOW_OFFSET & 0FFh = 071 mov dh, JRIDE_COMMAND_BLOCK_REGISTER_WINDOW_OFFSET >> 872 %else73 add dx, JRIDE_COMMAND_BLOCK_REGISTER_WINDOW_OFFSET74 %endif75 OutputToJrIdeRegister:76 mov bx, dx77 mov [cs:bx], al78 ret79 ALIGN JUMP_ALIGN80 OutputALtoIOmappedIdeRegisterInDL:81 %endif ; MODULE_JRIDE82 %endif ; MODULE_8BIT_IDE64 %ifdef MODULE_8BIT_IDE 65 mov dh, [di+DPT_ATA.bDevice] 66 %ifdef MODULE_JRIDE 67 test dh, dh 68 jnz SHORT OutputALtoIOmappedIdeRegisterInDL 69 70 %if JRIDE_COMMAND_BLOCK_REGISTER_WINDOW_OFFSET & 0FFh = 0 71 mov dh, JRIDE_COMMAND_BLOCK_REGISTER_WINDOW_OFFSET >> 8 72 %else 73 add dx, JRIDE_COMMAND_BLOCK_REGISTER_WINDOW_OFFSET 74 %endif 75 OutputToJrIdeRegister: 76 mov bx, dx 77 mov [cs:bx], al 78 ret 79 ALIGN JUMP_ALIGN 80 OutputALtoIOmappedIdeRegisterInDL: 81 %endif ; MODULE_JRIDE 82 %endif ; MODULE_8BIT_IDE 83 83 84 84 mov bl, IDEVARS.wPort … … 114 114 ;-------------------------------------------------------------------- 115 115 IdeIO_InputToALfromIdeRegisterInDL: 116 %ifdef MODULE_8BIT_IDE117 mov dh, [di+DPT_ATA.bDevice]118 %ifdef MODULE_JRIDE119 test dh, dh120 jnz SHORT .InputToALfromIOmappedIdeRegisterInDL121 122 %if JRIDE_COMMAND_BLOCK_REGISTER_WINDOW_OFFSET & 0FFh = 0123 mov dh, JRIDE_COMMAND_BLOCK_REGISTER_WINDOW_OFFSET >> 8124 %else125 add dx, JRIDE_COMMAND_BLOCK_REGISTER_WINDOW_OFFSET126 %endif127 mov bx, dx128 mov al, [cs:bx]129 ret130 .InputToALfromIOmappedIdeRegisterInDL:131 %endif ; MODULE_JRIDE132 %endif ; MODULE_8BIT_IDE116 %ifdef MODULE_8BIT_IDE 117 mov dh, [di+DPT_ATA.bDevice] 118 %ifdef MODULE_JRIDE 119 test dh, dh 120 jnz SHORT .InputToALfromIOmappedIdeRegisterInDL 121 122 %if JRIDE_COMMAND_BLOCK_REGISTER_WINDOW_OFFSET & 0FFh = 0 123 mov dh, JRIDE_COMMAND_BLOCK_REGISTER_WINDOW_OFFSET >> 8 124 %else 125 add dx, JRIDE_COMMAND_BLOCK_REGISTER_WINDOW_OFFSET 126 %endif 127 mov bx, dx 128 mov al, [cs:bx] 129 ret 130 .InputToALfromIOmappedIdeRegisterInDL: 131 %endif ; MODULE_JRIDE 132 %endif ; MODULE_8BIT_IDE 133 133 mov bl, IDEVARS.wPort 134 134 call GetIdePortToDX -
trunk/XTIDE_Universal_BIOS/Src/Device/IDE/IdeTransfer.asm
r402 r414 20 20 ; Structure containing variables for PIO transfer functions. 21 21 ; This struct must not be larger than IDEPACK without INTPACK. 22 struc PIOVARS 23 .wDataPort resb 2 ; 0 , IDE Data Port24 .fnXfer resb 2 ; 2 , Offset to transfer function25 .wSectorsInBlock resb 2 ; 4 , Block size in sectors22 struc PIOVARS ; Must not be larger than 9 bytes! See IDEPACK in RamVars.inc. 23 .wDataPort resb 2 ; 0-1, IDE Data Port 24 .fnXfer resb 2 ; 2-3, Offset to transfer function 25 .wSectorsInBlock resb 2 ; 4-5, Block size in sectors 26 26 .bSectorsLeft resb 1 ; 6, Sectors left to transfer 27 27 resb 1 ; 7, IDEPACK.bDeviceControl -
trunk/XTIDE_Universal_BIOS/Src/Device/IDE/JrIdeTransfer.asm
r412 r414 20 20 ; Structure containing variables for PIO transfer functions. 21 21 ; This struct must not be larger than IDEPACK without INTPACK. 22 struc MEMPIOVARS 23 .wSectorsInBlock resb 2 ; 0, Block size in sectors 24 .bSectorsLeft resb 1 ; 2, Sectors left to transfer 25 .bSectorsDone resb 1 ; 3, Number of sectors xferred 26 resb 3 ; 4, 5, 6 22 struc MEMPIOVARS ; Must not be larger than 9 bytes! See IDEPACK in RamVars.inc. 23 .wSectorsInBlock resb 2 ; 0-1, Block size in sectors 24 .fpDPT resb 4 ; 2-5, Far pointer to DPT 25 .bSectorsLeft resb 1 ; 6, Sectors left to transfer 27 26 resb 1 ; 7, IDEPACK.bDeviceControl 28 . fpDPT resb 4 ; 8, Far pointer to DPT27 .bSectorsDone resb 1 ; 8, Number of sectors xferred 29 28 endstruc 30 29 -
trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h.asm
r395 r414 45 45 %ifdef MODULE_HOTKEYS 46 46 call DriveXlate_ToOrBack 47 %endif48 47 mov [RAMVARS.xlateVars+XLATEVARS.bXlatedDrv], dl 48 %endif 49 49 50 50 call FindDPT_ForDriveNumberInDL ; DS:DI points to our DPT, or NULL if not our drive … … 129 129 mov [bp+IDEPACK.intpack+INTPACK.si], si 130 130 mov [bp+IDEPACK.intpack+INTPACK.bx], bx 131 %ifdef MODULE_HOTKEYS 131 132 mov [bp+IDEPACK.intpack+INTPACK.dh], dh 133 %else 134 mov [bp+IDEPACK.intpack+INTPACK.dx], dx 135 %endif 132 136 mov [bp+IDEPACK.intpack+INTPACK.cx], cx 133 137 mov [bp+IDEPACK.intpack+INTPACK.ax], ax … … 135 139 pop WORD [bp+IDEPACK.intpack+INTPACK.flags] 136 140 call RamVars_GetSegmentToDS 137 cmp dl, [RAMVARS.xlateVars+XLATEVARS.bXlatedDrv] 141 142 %ifdef MODULE_HOTKEYS 143 cmp dl, [RAMVARS.xlateVars+XLATEVARS.bXlatedDrv] ; DL is still drive number? 138 144 je SHORT .ExchangeInt13hHandlers 139 mov [bp+IDEPACK.intpack+INTPACK.dl], dl 145 mov [bp+IDEPACK.intpack+INTPACK.dl], dl ; Something is returned in DL 140 146 ALIGN JUMP_ALIGN 141 147 .ExchangeInt13hHandlers: 148 %endif 149 142 150 %ifdef USE_186 143 151 push Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH … … 192 200 Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH_ALHasDriveNumber: 193 201 call Int13h_SetErrorCodeToBdaAndToIntpackInSSBPfromAH_ALHasDriveNumber 202 194 203 %else 195 204 call Int13h_SetErrorCodeToBdaAndToIntpackInSSBPfromAH 196 205 %endif 206 197 207 Int13h_ReturnFromHandlerWithoutStoringErrorCode: 198 208 or WORD [bp+IDEPACK.intpack+INTPACK.flags], FLG_FLAGS_IF ; Return with interrupts enabled … … 265 275 mov bx, BDA.bHDLastSt 266 276 test al, al 267 js .HardDisk277 js SHORT .HardDisk 268 278 mov bl, BDA.bFDRetST & 0xff 269 279 .HardDisk: -
trunk/XTIDE_Universal_BIOS/Src/Handlers/Int19h.asm
r413 r414 29 29 ;-------------------------------------------------------------------- 30 30 Int19h_BootLoaderHandler: 31 sti ; Allow timer interrupts 32 LOAD_BDA_SEGMENT_TO es, ax ; Load BDA segment (zero) to ES 31 sti ; Enable interrupts 32 cld ; String instructions to increment pointers 33 LOAD_BDA_SEGMENT_TO es, ax ; Load BDA segment (zero) to ES 33 34 ; Fall to .PrepareBootLoaderStack 34 35
Note:
See TracChangeset
for help on using the changeset viewer.