On Sun, 2008-10-12 at 18:50 -0400, Kevin O'Connor wrote:
> As an aside, is there any interest in using SeaBIOS with kvm?
>
> SeaBIOS is a port of bochs bios to gcc. I've been using SeaBIOS
> (along with coreboot) to boot and provide bios functions on real
> hardware. It works fine under qemu also.
Sounds interesting to me. The VirtaulBox project has also made
improvements to the bochs bios that might be nice to pull in. I'd also
like to see the TianoCore EFI image, that ia64 is using, work on x86.
There's an x86 version for QEMU on the QEMU downloads page. With the
(wip) patch below to increase the bios reserved region to 1MB I can boot
to the EFI shell, but KVM is missing some emulation to boot Linux (works
with --no-kvm, maybe an ff 6f opcode?). I haven't had a chance to debug
it further. Thanks,
Alex
Increase BIOS memory region to 1MB
Signed-off-by: Alex Williamson <[EMAIL PROTECTED]>
--
diff --git a/bios/rombios.c b/bios/rombios.c
index 818ce63..57e5139 100644
--- a/bios/rombios.c
+++ b/bios/rombios.c
@@ -4579,17 +4579,17 @@ ASM_END
break;
case 5:
/* 3 pages before the bios, we map the vmx tss pages */
- set_e820_range(ES, regs.u.r16.di, 0xfffbd000L,
- 0xfffc0000L, 0, 0, 2);
+ set_e820_range(ES, regs.u.r16.di, 0xffdfd000L,
+ 0xffe00000L, 0, 0, 2);
regs.u.r32.ebx = 6;
regs.u.r32.eax = 0x534D4150;
regs.u.r32.ecx = 0x14;
CLEAR_CF();
return;
case 6:
- /* 256KB BIOS area at the end of 4 GB */
+ /* 1MB BIOS area at the end of 4 GB */
set_e820_range(ES, regs.u.r16.di,
- 0xfffc0000L, 0x00000000L ,0, 0, 2);
+ 0xffe00000L, 0x00000000L ,0, 0, 2);
if (extra_highbits_memory_size ||
extra_lowbits_memory_size)
regs.u.r32.ebx = 7;
else
diff --git a/libkvm/libkvm-x86.c b/libkvm/libkvm-x86.c
index a8cca15..d9850a4 100644
--- a/libkvm/libkvm-x86.c
+++ b/libkvm/libkvm-x86.c
@@ -42,7 +42,7 @@ static int kvm_init_tss(kvm_context_t kvm)
* this address is 3 pages before the bios, and the bios should
present
* as unavaible memory
*/
- r = kvm_set_tss_addr(kvm, 0xfffbd000);
+ r = kvm_set_tss_addr(kvm, 0xffdfd000);
if (r < 0) {
fprintf(stderr, "kvm_init_tss: unable to set tss
addr\n");
return r;
--
Alex Williamson HP Open Source & Linux Org.
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html