From fc7c34c17fd79c247c7f2b172171f20402fbd495 Mon Sep 17 00:00:00 2001 From: Mark McLoughlin Date: Jul 31 2009 15:12:00 +0000 Subject: - Add KSM support - Require bochs-bios >= 2.3.8-0.8 for latest kvm bios updates --- diff --git a/qemu-add-ksm-support.patch b/qemu-add-ksm-support.patch new file mode 100644 index 0000000..142fb9a --- /dev/null +++ b/qemu-add-ksm-support.patch @@ -0,0 +1,31 @@ +From 511a4f5ab30a36fdaa48fb0d146cfc3f123b4f0a Mon Sep 17 00:00:00 2001 +From: Izik Eidus +Date: Tue, 28 Jul 2009 19:14:26 +0300 +Subject: [PATCH] kvm userspace: ksm support + +rfc for ksm support to kvm userpsace. + +Signed-off-by: Izik Eidus +Signed-off-by: Mark McLoughlin +Fedora-patch: qemu-add-ksm-support.patch +--- + exec.c | 3 +++ + 1 files changed, 3 insertions(+), 0 deletions(-) + +diff --git a/exec.c b/exec.c +index 2134697..88bcff5 100644 +--- a/exec.c ++++ b/exec.c +@@ -2578,6 +2578,9 @@ ram_addr_t qemu_ram_alloc(ram_addr_t size) + new_block->host = file_ram_alloc(size, mem_path); + if (!new_block->host) { + new_block->host = qemu_vmalloc(size); ++#ifdef MADV_MERGEABLE ++ madvise(new_block->host, size, MADV_MERGEABLE); ++#endif + } + new_block->offset = last_ram_offset; + new_block->length = size; +-- +1.6.2.5 + diff --git a/qemu.spec b/qemu.spec index 159d3c4..9b6ad25 100644 --- a/qemu.spec +++ b/qemu.spec @@ -4,7 +4,7 @@ Summary: QEMU is a FAST! processor emulator Name: qemu Version: 0.10.91 -Release: 0.1.%{kvmvertag}%{?dist} +Release: 0.2.%{kvmvertag}%{?dist} # Epoch because we pushed a qemu-1.0 package Epoch: 2 License: GPLv2+ and LGPLv2+ and BSD @@ -26,6 +26,9 @@ Patch02: qemu-fix-linux-user-build-on-ppc.patch # Make sure multiboot.bin/extboot.bin gets installed Patch03: qemu-fix-optionrom-install.patch +# Add KSM support - see https://fedoraproject.org/wiki/Features/KSM +Patch04: qemu-add-ksm-support.patch + BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: SDL-devel zlib-devel which texi2html gnutls-devel cyrus-sasl-devel BuildRequires: rsync dev86 iasl @@ -110,7 +113,7 @@ Group: Development/Tools Requires: %{name}-common = %{epoch}:%{version}-%{release} Requires: gpxe-roms-qemu Requires: vgabios -Requires: bochs-bios >= 2.3.8-0.5 +Requires: bochs-bios >= 2.3.8-0.8 Provides: kvm = 85 Obsoletes: kvm < 85 @@ -209,6 +212,7 @@ such as kvmtrace and kvm_stat. %patch01 -p1 %patch02 -p1 %patch03 -p1 +%patch04 -p1 %build # systems like rhel build system does not have a recent enough linker so @@ -473,6 +477,10 @@ getent passwd qemu >/dev/null || \ %{_mandir}/man1/qemu-img.1* %changelog +* Fri Jul 31 2009 Mark McLoughlin - 2:0.10.91-0.2.rc1.rc0 +- Add KSM support +- Require bochs-bios >= 2.3.8-0.8 for latest kvm bios updates + * Thu Jul 30 2009 Mark McLoughlin - 2:0.10.91-0.1.rc1.rc0 - Update to qemu-kvm-0.11.0-rc1-rc0 - This is a pre-release of the official -rc1