Several minor comment improvements.
Rearrange some definitions to make them more clear.
+Split rombios32.c up into multiple files.
+
+Review changes committed to coreboot, virtualbox, qemu, kvm, and bochs
+cvs tip.
+
+Alter ISRs so that they do not enable irqs. Only call out to other
+bios functions after minimizing stack usage.
+
+Try to write a script to analyze stack usage of 16bit code.
+
Audit all sti/cli calls. Audit all call16 calls to make sure flags is
setup properly with respect to irqs.
Cleanup setting of ES on GET/SET_BDA
-Make sure inline assembly isn't preventing inlining of calling
-functions.
-
-Convert remaining parts of rombios.c to new code.
-
-Convert rombios32 and apm bios stuff to new code.
+Possibly implement 32bit pcibios support.
Allow one to select adding 32 bit code to 0xf000 or in a separate
location.
u8 c = GET_VAR(CS, *s);
if (!c)
break;
- outb(c, 0x8900);
+ outb(c, PORT_BIOS_APM);
s++;
}
}
#define CMOS_FLOPPY_DRIVE_TYPE 0x10
#define CMOS_DISK_DATA 0x12
#define CMOS_EQUIPMENT_INFO 0x14
-#define CMOS_MEM_BASE_LOW 0x17
-#define CMOS_MEM_BASE_HIGH 0x18
#define CMOS_DISK_DRIVE1_TYPE 0x19
#define CMOS_DISK_DRIVE2_TYPE 0x1a
#define CMOS_DISK_DRIVE1_CYL 0x1b
#define PORT_FD_STATUS 0x03f4
#define PORT_FD_DATA 0x03f5
#define PORT_HD_DATA 0x03f6
+#define PORT_FD_DIR 0x03f7
+#define PORT_BIOS_DEBUG 0x0403
+#define PORT_BIOS_APM 0x8900
// PORT_PIC1 bitdefs
#define PIC1_IRQ5 (1<<5)
call16_int(0x10, &br);
}
-// XXX - move PORT_DEBUG to standard place?
-#define PORT_DEBUG 0x403
-
// Write a charcter to the framebuffer.
static void
putc(u16 action, char c)
{
- outb(c, PORT_DEBUG);
+ outb(c, PORT_BIOS_DEBUG);
if (action) {
if (c == '\n')
screenc('\r');
#include "cmos.h" // CMOS_*
#include "util.h" // memset
#include "biosvar.h" // struct bios_data_area_s
-#include "ata.h" // ata_detect
+#include "ata.h" // hard_drive_setup
#include "kbd.h" // kbd_setup
#include "disk.h" // floppy_drive_setup
// mov CMOS Equipment Byte to BDA Equipment Word
SET_BDA(equipment_list_flags, inb_cmos(CMOS_EQUIPMENT_INFO));
-}
-static void
-init_handlers()
-{
// set vector 0x79 to zero
// this is used by 'gardian angel' protection system
SET_BDA(ivecs[0x79].seg, 0);
BX_INFO("Start bios\n");
init_bda();
- init_handlers();
init_ebda();
timer_setup();
start = (void *)(bios_table_cur_addr);
#endif
- p = (char *)start + sizeof(struct smbios_entry_point);
+ p = (char *)start + sizeof(struct smbios_entry_point);
#define add_struct(fn) { \
q = (fn); \
// This file may be distributed under the terms of the GNU GPLv3 license.
#include "util.h" // irq_restore
-#include "biosvar.h" // CONFIG_BIOS_TABLE
+#include "biosvar.h" // BIOS_CONFIG_TABLE
#include "ioport.h" // inb
#include "cmos.h" // inb_cmos