1 // 16bit code to access hard drives.
3 // Copyright (C) 2008 Kevin O'Connor <kevin@koconnor.net>
4 // Copyright (C) 2002 MandrakeSoft S.A.
6 // This file may be distributed under the terms of the GNU GPLv3 license.
8 #include "disk.h" // floppy_13
9 #include "biosvar.h" // struct bregs
10 #include "util.h" // debug_enter
13 disk_13(struct bregs *regs, u8 drive)
19 handle_legacy_disk(struct bregs *regs, u8 drive)
22 floppy_13(regs, drive);
27 int13_cdrom(regs); // xxx
36 handle_40(struct bregs *regs)
39 handle_legacy_disk(regs, regs->dl);
43 // INT 13h Fixed Disk Services Entry Point
45 handle_13(struct bregs *regs)
50 if (regs->ah >= 0x4a || regs->ah <= 0x4d) {
52 } else if (cdemu_isactive() && cdrom_emulated_drive()) {
56 handle_legacy_disk(regs, drive);
60 // record completion in BIOS task complete flag
62 handle_76(struct bregs *regs)
65 SET_BDA(floppy_harddisk_info, 0xff);