- Timestamp:
- Mar 3, 2011, 6:33:01 PM (14 years ago)
- google:author:
- krille_n_@hotmail.com
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/XTIDE_Universal_BIOS/Src/Initialization/DriveXlate.asm
r99 r126 95 95 ALIGN JUMP_ALIGN 96 96 DriveXlate_SwapFloppyDriveOrHardDisk: 97 test dl, 80h ; Hard disk? 98 jnz SHORT .SwapHardDisk ; If so, jump to swap 99 ; Fall to .SwapFloppyDrive 100 101 ;-------------------------------------------------------------------- 102 ; .SwapFloppyDrive 103 ; Parameters: 104 ; DL: Drive number to be possibly swapped 105 ; DS: RAMVARS segment 106 ; Returns: 107 ; DL: Translated drive number 108 ; Corrupts registers: 109 ; AX 110 ;-------------------------------------------------------------------- 111 .SwapFloppyDrive: 112 eMOVZX ax, BYTE [RAMVARS.xlateVars+XLATEVARS.bFDSwap] 113 jmp SHORT SwapDrive 114 115 ;-------------------------------------------------------------------- 116 ; .SwapHardDisk 117 ; Parameters: 118 ; DL: Drive number to be possibly swapped 119 ; DS: RAMVARS segment 120 ; Returns: 121 ; DL: Translated drive number 122 ; Corrupts registers: 123 ; AX 124 ;-------------------------------------------------------------------- 125 ALIGN JUMP_ALIGN 126 .SwapHardDisk: 127 mov ah, 80h 97 mov ah, 80h ; Assume hard disk 128 98 mov al, BYTE [RAMVARS.xlateVars+XLATEVARS.bHDSwap] 99 test dl, ah ; Hard disk? 100 jnz SHORT SwapDrive ; If so, jump to swap 101 mov al, BYTE [RAMVARS.xlateVars+XLATEVARS.bFDSwap] 102 cbw 129 103 ; Fall to SwapDrive 130 104 … … 140 114 ; Nothing 141 115 ;-------------------------------------------------------------------- 116 ALIGN JUMP_ALIGN 142 117 SwapDrive: 143 118 cmp ah, dl ; Swap DL from 00h/80h to xxh?
Note:
See TracChangeset
for help on using the changeset viewer.