Changeset 544 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs
- Timestamp:
- Apr 17, 2013, 5:16:00 PM (12 years ago)
- google:author:
- aitotat@gmail.com
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs/CreateDPT.asm
r543 r544 122 122 123 123 %ifdef MODULE_EBIOS 124 %ifdef CREATE_COMPATIBLE_DPT 125 ; Store P-Cylinders here for Compatible DPTs when FLGL_DPT_LBA is not set 126 ; or when drive has over 15,482,880 sectors 127 mov [di+DPT.wPchsCylinders], ax 128 %endif 124 129 test cl, FLGL_DPT_LBA 125 130 jz SHORT .NoLbaSoNoEBIOS … … 128 133 ; we only need P-Cylinders so we can return it from AH=48h 129 134 call AtaGeometry_GetLbaSectorCountToBXDXAXfromAtaInfoInESSI 130 sub ax, MAX_SECTOR_COUNT_TO_RETURN_PCHS& 0FFFFh131 sbb dx, MAX_SECTOR_COUNT_TO_RETURN_PCHS>> 16135 sub ax, (MAX_SECTOR_COUNT_TO_RETURN_PCHS+1) & 0FFFFh 136 sbb dx, (MAX_SECTOR_COUNT_TO_RETURN_PCHS+1) >> 16 132 137 sbb bx, BYTE 0 133 j aSHORT .StoreNumberOfLbaSectors138 jnc SHORT .StoreNumberOfLbaSectors 134 139 135 140 ; Since we might have altered the default P-CHS parameters to be … … 146 151 147 152 ; We could remove wPchsCylinders from DPT if we calculate it on AH=48h 148 ; but that would require extra code so we save ROM space instead.153 ; (and for compatible DPTs) but that would require extra code so we save ROM space instead. 149 154 mov [di+DPT.wPchsCylinders], ax 150 155
Note:
See TracChangeset
for help on using the changeset viewer.