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)
20 handle_legacy_disk(struct bregs *regs, u8 drive)
23 floppy_13(regs, drive);
28 int13_cdrom(regs); // xxx
37 handle_40(struct bregs *regs)
40 handle_legacy_disk(regs, regs->dl);
44 // INT 13h Fixed Disk Services Entry Point
46 handle_13(struct bregs *regs)
52 if (regs->ah >= 0x4a || regs->ah <= 0x4d) {
54 } else if (cdemu_isactive() && cdrom_emulated_drive()) {
58 handle_legacy_disk(regs, drive);
62 // record completion in BIOS task complete flag
64 handle_76(struct bregs *regs)
67 SET_BDA(floppy_harddisk_info, 0xff);