diff --git a/python-virtinst.spec b/python-virtinst.spec index 495fb44..ba30a04 100644 --- a/python-virtinst.spec +++ b/python-virtinst.spec @@ -17,12 +17,14 @@ Summary: Python modules and utilities for installing virtual machines Name: python-%{appname} Version: 0.500.2 -Release: 2%{_extra_release} +Release: 3%{_extra_release} Source0: http://virt-manager.org/download/sources/%{appname}/%{appname}-%{version}.tar.gz # Improve clone progress reporting (bz 550870) Patch1: %{appname}-%{version}-improve-clone-progress.patch # virt-install: Fix windows installs Patch2: %{appname}-%{version}-fix-windows-installs.patch +# Enable x2apic for new KVM guests +Patch3: %{appname}-%{version}-use-x2apic.patch License: GPLv2+ Group: Development/Libraries @@ -52,6 +54,7 @@ and install new VMs) and virt-clone (clone an existing virtual machine). %setup -q -n %{appname}-%{version} %patch1 -p1 %patch2 -p1 +%patch3 -p1 %build python setup.py build @@ -87,6 +90,9 @@ rm -rf $RPM_BUILD_ROOT %{_bindir}/virt-convert %changelog +* Mon Mar 22 2010 Cole Robinson - 0.500.2-3.fc14 +- Enable x2apic for new KVM guests + * Sun Mar 21 2010 Cole Robinson - 0.500.2-2.fc14 - Improve clone progress reporting (bz 550870) - virt-install: Fix windows installs diff --git a/virtinst-0.500.2-use-x2apic.patch b/virtinst-0.500.2-use-x2apic.patch new file mode 100644 index 0000000..3cb0256 --- /dev/null +++ b/virtinst-0.500.2-use-x2apic.patch @@ -0,0 +1,54 @@ +diff -rup virtinst-0.500.2/virtinst/CapabilitiesParser.py foo/virtinst/CapabilitiesParser.py +--- virtinst-0.500.2/virtinst/CapabilitiesParser.py 2010-02-08 23:07:04.000000000 -0500 ++++ foo/virtinst/CapabilitiesParser.py 2010-03-22 15:05:19.530904000 -0400 +@@ -90,6 +90,7 @@ class Host(object): + def __init__(self, node = None): + # e.g. "i686" or "x86_64" + self.arch = None ++ self.model = None + + self.features = CapabilityFeatures() + self.topology = None +@@ -115,6 +116,8 @@ class Host(object): + while n: + if n.name == "arch": + self.arch = n.content ++ elif n.name == "model": ++ self.model = n.content + elif n.name == "features": + self.features = CapabilityFeatures(n) + n = n.next +diff -rup virtinst-0.500.2/virtinst/Guest.py foo/virtinst/Guest.py +--- virtinst-0.500.2/virtinst/Guest.py 2010-03-22 15:03:37.220776000 -0400 ++++ foo/virtinst/Guest.py 2010-03-22 15:07:16.032765000 -0400 +@@ -695,6 +695,22 @@ class Guest(object): + """ + return self.clock.get_xml_config() + ++ def _get_cpu_xml(self): ++ """ ++ Return XML ++ """ ++ xml = "" ++ is_kvm = self.type == "kvm" ++ model = self._caps.host.model ++ ++ if is_kvm and model: ++ xml += " \n" ++ xml += " %s\n" % model ++ xml += " \n" ++ xml += " " ++ ++ return xml ++ + def _get_seclabel_xml(self): + """ + Return XML +@@ -718,6 +734,7 @@ class Guest(object): + xml = _util.xml_append(xml, + self.installer.get_install_xml(self, install)) + xml = _util.xml_append(xml, self._get_features_xml()) ++ xml = _util.xml_append(xml, self._get_cpu_xml()) + xml = _util.xml_append(xml, self._get_clock_xml()) + return xml +