Changeset 558 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs/CompatibleDPT.asm
- Timestamp:
- Jun 23, 2013, 3:52:31 PM (12 years ago)
- google:author:
- krille_n_@hotmail.com
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs/CompatibleDPT.asm
r550 r558 139 139 140 140 mov al, [si+DPT.bLchsSectorsPerTrack] 141 %ifdef USE_186 141 %ifndef USE_186 142 call StoswALandChecksumFromDL ; Bytes 14 (Logical sectors per track) and 15 (Checksum) 143 jmp SHORT FillStandardDPTtoESDIfromDPTinDSSI.RestoreOffsetsAndReturn 144 %else 142 145 push FillStandardDPTtoESDIfromDPTinDSSI.RestoreOffsetsAndReturn 143 jmp StoswALandChecksumFromDL ; Bytes 14 (Logical sectors per track) and 15 (Checksum) 144 %else 145 call StoswALandChecksumFromDL 146 jmp SHORT FillStandardDPTtoESDIfromDPTinDSSI.RestoreOffsetsAndReturn 147 %endif 146 ; Fall to StoswALandChecksumFromDL 147 %endif 148 149 150 ;-------------------------------------------------------------------- 151 ; StoswALandChecksumFromDL 152 ; Parameters: 153 ; AL: Last byte to store before checksum byte 154 ; DL: Sum of bytes so far 155 ; ES:DI: Ptr to where to store AL and Checksum byte 156 ; Returns: 157 ; DL: Sum of bytes so far 158 ; DI: Incremented by 2 159 ; Corrupts registers: 160 ; Nothing 161 ;-------------------------------------------------------------------- 162 StoswALandChecksumFromDL: 163 mov ah, al 164 add ah, dl 165 neg ah 166 stosw 167 ret 148 168 149 169 … … 226 246 %ifdef MODULE_ADVANCED_ATA 227 247 or ah, [si+DPT_ADVANCED_ATA.bPioMode] 228 jz SHORT . NoDotSetFastPioFlag248 jz SHORT .DoNotSetFastPioFlag 229 249 cmp WORD [si+DPT_ADVANCED_ATA.wControllerID], BYTE 0 230 je SHORT . NoDotSetFastPioFlag250 je SHORT .DoNotSetFastPioFlag 231 251 inc cx ; FLG_FAST_PIO_ENABLED 232 . NoDotSetFastPioFlag:252 .DoNotSetFastPioFlag: 233 253 %endif 234 254 call StoswThenAddALandAHtoDL ; Bytes 8 and 9 … … 276 296 ret 277 297 278 279 ;--------------------------------------------------------------------280 ; StoswALandChecksumFromDL281 ; Parameters:282 ; AL: Last byte to store before checksum byte283 ; DL: Sum of bytes so far284 ; ES:DI: Ptr to where to store AL and Checksum byte285 ; Returns:286 ; DL: Sum of bytes so far287 ; DI: Incremented by 2288 ; Corrupts registers:289 ; Nothing290 ;--------------------------------------------------------------------291 StoswALandChecksumFromDL:292 mov ah, al293 add ah, dl294 neg ah295 stosw296 ret
Note:
See TracChangeset
for help on using the changeset viewer.