I did find a bug, after cosimulating plex86+bochs only a couple thousand
instructions into the boot sequence. Here's a replacement for a function
in kernel/emulation/access.c.
I implemented a bunch of instructions along the way, and need to
code a bunch more. I'm also working on booting FreeDOS. My plan
is a CVS sync by this weekend. Sorry I haven't got to that.
Might as well start off with a CVS version 0.1.0 that can
run FreeDOS & MSDOS. :^)
-Kevin
void
write_RMW_virtual(vm_t *vm, void *data, unsigned size)
{
if (vm->guest_cpu.cr0.fields.pg) {
if (vm->guest_cpu.address_xlation.pages == 1) {
write_physical(vm, vm->guest_cpu.address_xlation.paddress1, size, data);
}
else {
write_physical(vm, vm->guest_cpu.address_xlation.paddress1,
vm->guest_cpu.address_xlation.len1,
data);
write_physical(vm, vm->guest_cpu.address_xlation.paddress2,
vm->guest_cpu.address_xlation.len2,
((Bit8u *) data) + vm->guest_cpu.address_xlation.len1);
}
}
else {
write_physical(vm, vm->guest_cpu.address_xlation.paddress1, size, data);
}
}