Changeset 181 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs
- Timestamp:
- Nov 13, 2011, 3:38:40 PM (13 years ago)
- google:author:
- krille_n_@hotmail.com
- Location:
- trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs/AccessDPT.asm
r173 r181 78 78 ; Only need to limit sectors for LBA assist 79 79 test BYTE [di+DPT.bFlagsLow], FLG_DRVNHEAD_LBA 80 j nz SHORT .ReturnLbaAssistedLCHS80 jz SHORT AccessDPT_ShiftPCHinBXDXtoLCH 81 81 82 ; P-CHS to L-CHS translation when necessary83 j mp SHORT AccessDPT_ShiftPCHinBXDXtoLCH82 cmp WORD [di+DPT.dwCylinders+2], BYTE 0 83 jnz SHORT .Return_MAX_LCHS_CYLINDERS 84 84 85 .ReturnLbaAssistedLCHS: 86 cmp WORD [di+DPT.dwCylinders+2], BYTE 0 87 jz SHORT .LimitCylindersTo1024 85 ; Limit cylinders to 1024 86 cmp bx, MAX_LCHS_CYLINDERS 87 jb SHORT .Return 88 ALIGN JUMP_ALIGN 89 .Return_MAX_LCHS_CYLINDERS: 88 90 mov bx, MAX_LCHS_CYLINDERS 89 .LimitCylindersTo1024: 90 MIN_U bx, MAX_LCHS_CYLINDERS 91 ALIGN JUMP_ALIGN, ret 92 .Return: 91 93 ret 92 94 … … 114 116 jmp SHORT .ShiftLoop 115 117 .LimitHeadsTo255: ; DOS does not support drives with 256 heads 116 sub dl, dh ; BH set only when 256 logical heads118 sub dl, dh ; DH set only when 256 logical heads 117 119 xor dh, dh 118 120 ret -
trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs/CreateDPT.asm
r175 r181 66 66 %ifdef MODULE_SERIAL 67 67 cmp byte [cs:bp+IDEVARS.bDevice], DEVICE_SERIAL_PORT 68 jnz . around68 jnz .StoreAddressing 69 69 or byte [di+DPT.bFlagsHigh], FLGH_DPT_SERIAL_DEVICE 70 .around: 71 %endif 72 70 %endif 73 71 ; Fall to .StoreAddressing 74 72 … … 117 115 118 116 ; We need to get number of bits to shift for translation 119 push bx120 117 push ax 121 118 eMOVZX dx, bl ; Heads now in DX 122 xchg bx, ax ; Sectors now in BX 123 call AccessDPT_ShiftPCHinBXDXtoLCH 119 xchg bx, ax ; Cylinders now in BX 120 call AccessDPT_ShiftPCHinBXDXtoLCH ; Leaves AX untouched 121 xchg bx, ax ; Restore HeadsAndSectors to BX 124 122 or cl, ADDRESSING_MODE_PCHS<<ADDRESSING_MODE_FIELD_POSITION 125 123 or [di+DPT.bFlagsLow], cl ; Store bits to shift 126 124 pop ax 127 pop bx128 125 ; Fall to .StoreChsFromAXBX 129 126 -
trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs/FindDPT.asm
r161 r181 167 167 ; CF: Set if wanted DPT found 168 168 ; Cleared if DPT not found 169 ; Unchanged if no drives 169 170 ; Corrupts registers: 170 171 ; Nothing unless corrupted by callback function -
trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs/RamVars.asm
r155 r181 93 93 test BYTE [cs:ROMVARS.wFlags], FLG_ROMVARS_FULLMODE 94 94 jnz SHORT .GetStolenSegmentToDS 95 %ifndef USE_186 95 96 mov di, LITE_MODE_RAMVARS_SEGMENT 96 97 mov ds, di 98 %else 99 push LITE_MODE_RAMVARS_SEGMENT 100 pop ds 101 %endif 97 102 ret 98 103 … … 183 188 LOAD_BDA_SEGMENT_TO es, cx, ! ; Zero CX 184 189 call RamVars_GetCountOfKnownDrivesToDL 185 MAX_U dl, [es:BDA.bHDCount]186 movcl, dl190 mov cl, [es:BDA.bHDCount] 191 MAX_U cl, dl 187 192 188 193 pop dx
Note:
See TracChangeset
for help on using the changeset viewer.