Skip to contentSkip to conversation

QEMU-KVM missing bits for E820 handling.

PATCH Applied Jes Sorensen 2 participants 2 messages Mar 9, 2010 – Mar 11, 2010

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 QEMU-KVM missing bits for E820 handling.

Hi,

This is the last piece needed for QEMU-KVM to match the changes that went into upstream QEMU.

Cheers,
Jes

Use qemu-cfg to provide the BIOS with an optional table of e820 entries.

The missing bits for qemu-kvm.git to match what qemu does.

---
 qemu-kvm-x86.c |    7 +++++++
 1 file changed, 7 insertions(+)
qemu-kvm-x86.c +7 -0
Index: qemu-kvm/qemu-kvm-x86.c
===================================================================
@@ -37,6 +37,13 @@ int kvm_set_tss_addr(kvm_context_t kvm, 
 {
 #ifdef KVM_CAP_SET_TSS_ADDR
 	int r;
+        /*
+         * Tell fw_cfg to notify the BIOS to reserve the range.
+         */
+        if (e820_add_entry(addr, 0x4000, E820_RESERVED) < 0) {
+            perror("e820_add_entry() table is full");
+            exit(1);
+        }
 
 	r = kvm_ioctl(kvm_state, KVM_CHECK_EXTENSION, KVM_CAP_SET_TSS_ADDR);
 	if (r > 0) {
Applied
#1 lore raw
Quoted 5 lines · Jes Sorensen

Hi,

This is the last piece needed for QEMU-KVM to match the changes that went into upstream QEMU.

Applied, thanks.

Signature · 1 line
error compiling committee.c: too many arguments to function