Changeset 473 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs/CreateDPT.asm
- Timestamp:
- Oct 10, 2012, 6:22:23 PM (13 years ago)
- google:author:
- aitotat@gmail.com
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs/CreateDPT.asm
r445 r473 28 28 ; Parameters: 29 29 ; BH: Drive Select byte for Drive and Head Register 30 ; DX: Autodetected port (for devices that support autodetection) 30 31 ; ES:SI: Ptr to 512-byte ATA information read from the drive 31 32 ; CS:BP: Ptr to IDEVARS for the controller … … 47 48 ; Parameters: 48 49 ; BH: Drive Select byte for Drive and Head Register 50 ; DX: Autodetected port (for devices that support autodetection) 49 51 ; DS:DI: Ptr to Disk Parameter Table 50 52 ; CS:BP: Ptr to IDEVARS for the controller … … 55 57 ;-------------------------------------------------------------------- 56 58 .InitializeDPT: 57 mov [di+DPT.bIdevarsOffset], bp ; IDEVARS must start in first 256 bytes of ROM59 call CreateDPT_StoreIdevarsOffsetAndBasePortFromCSBPtoDPTinDSDI 58 60 ; Fall to .StoreDriveSelectAndDriveControlByte 59 61 … … 230 232 231 233 ;-------------------------------------------------------------------- 234 ; CreateDPT_StoreIdevarsOffsetAndBasePortFromCSBPtoDPTinDSDI 235 ; Parameters: 236 ; DX: Autodetected port (for devices that support autodetection) 237 ; DS:DI: Ptr to Disk Parameter Table 238 ; CS:BP: Ptr to IDEVARS for the controller 239 ; Returns: 240 ; Nothing 241 ; Corrupts registers: 242 ; AX 243 ;-------------------------------------------------------------------- 244 CreateDPT_StoreIdevarsOffsetAndBasePortFromCSBPtoDPTinDSDI: 245 mov [di+DPT.bIdevarsOffset], bp ; IDEVARS must start in first 256 bytes of ROM 246 247 %ifdef MODULE_8BIT_IDE 248 call DetectDrives_DoesIdevarsInCSBPbelongToXTCF 249 jne SHORT .DeviceUsesPortSpecifiedInIDEVARS 250 mov [di+DPT.wBasePort], dx 251 ret 252 .DeviceUsesPortSpecifiedInIDEVARS: 253 %endif ; MODULE_8BIT_IDE 254 255 mov ax, [cs:bp+IDEVARS.wBasePort] 256 mov [di+DPT.wBasePort], ax 257 ret 258 259 260 ;-------------------------------------------------------------------- 232 261 ; GetUserDefinedCapacityToBXAXandFlagsToCXandModeToDXfromROMVARS 233 262 ; Parameters:
Note:
See TracChangeset
for help on using the changeset viewer.