Changeset 501 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/Handlers
- Timestamp:
- Jan 26, 2013, 4:58:50 PM (12 years ago)
- google:author:
- aitotat@gmail.com
- Location:
- trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h/AH0h_HReset.asm
r491 r501 38 38 ;-------------------------------------------------------------------- 39 39 AH0h_HandlerForDiskControllerReset: 40 ; Reset Floppy Drives with INT 40h41 40 xor bx, bx ; Zero BH to assume no errors 42 41 or bl, dl ; Copy requested drive to BL 43 eCMOVS dl, bh ; Reset Floppy Drive(s) with 00h since DL has Hard Drive number44 45 xor ah, ah ; Disk Controller Reset46 int BIOS_DISKETTE_INTERRUPT_40h47 call BackupErrorCodeFromTheRequestedDriveToBH48 ; We do not reset Hard Drives if DL was 0xh on entry49 50 42 51 43 %ifdef MODULE_SERIAL_FLOPPY … … 69 61 %endif 70 62 71 ; Reset foreign Hard Drives (those handled by other BIOSes) 63 ; Reset foreign Floppy and Hard Drives (those handled by other BIOSes) 64 call ResetForeignDrives 72 65 test bl, bl ; If we were called with a floppy disk, then we are done, 73 66 jns SHORT .SkipHardDiskReset ; don't do hard disks. 74 call ResetForeignHardDisks75 67 76 68 ; Resetting our hard disks will modify dl and bl to be idevars offset based instead of drive number based, 77 69 ; such that this call must be the last in the list of reset routines called. 78 70 ; 79 ; This needs to happen after ResetForeign HardDisks, as that call may have set the error code for 80h,71 ; This needs to happen after ResetForeignDrives, as that call may have set the error code for 80h, 80 72 ; and we need to override that value if we are xlate'd into 80h with one of our drives. 81 73 ; … … 88 80 89 81 ;-------------------------------------------------------------------- 90 ; ResetForeign HardDisks82 ; ResetForeignDrives 91 83 ; Parameters: 92 ; BL: Requested Hard Drive (DL when entering AH=00h)84 ; BL: Requested Floppy or Hard Drive (DL when entering AH=00h) 93 85 ; DS: RAMVARS segment 94 86 ; Returns: … … 97 89 ; AX, DL 98 90 ;-------------------------------------------------------------------- 99 ResetForeign HardDisks:91 ResetForeignDrives: 100 92 ; If there are drives after our drives, those are already reset 101 93 ; since our INT 13h was called by some other BIOS. … … 103 95 ; There could be more in chain but let the previous one handle them. 104 96 mov dl, [RAMVARS.bFirstDrv] 105 or dl, 80h ; We may not have our drives at all !106 MIN_U dl, bl ; BL is always Hard Drive number97 or dl, 80h ; We may not have our drives at all so change 0 to 80h! 98 MIN_U dl, bl 107 99 108 100 xor ah, ah ; Disk Controller Reset … … 135 127 ; ResetHardDisksHandledByOurBIOS 136 128 ; Parameters: 129 ; BL: Requested drive (DL when entering AH=00h) 137 130 ; DS:DI: Ptr to DPT for requested drive 138 131 ; If DPT pointer is not available, or error result in BH won't be used anyway, -
trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h/AHDh_HReset.asm
r473 r501 65 65 call Interrupts_UnmaskInterruptControllerForDriveInDSDI 66 66 %endif 67 call Device_ResetMasterAndSlaveController68 ;jc SHORT .ReturnError ; CF would be set if slave drive present without master69 ; (error register has special values after reset)70 71 67 ; Initialize Master and Slave drives 72 68 call AccessDPT_GetIdevarsToCSBX
Note:
See TracChangeset
for help on using the changeset viewer.