libvirt: Drop MIN_LIBVIRT_REALTIME_VERSION

The updated minimum required libvirt (1.3.1) and QEMU (2.5.0) for
"Rocky" matches this now, so we can drop the compatibility code.

Also remove the now no longer needed exception
RealtimePolicyNotSupported().

From my examination of unit tests, no unit tests need to be removed.
The existing two tests with 'realtime' in the test name should remain:

  - test_get_guest_memory_backing_config_realtime()
  - test_get_guest_config_numa_host_instance_cpu_pinning_realtime()

Change-Id: Ieaa615f97a26569dd3b1ec176d6bb6fd8e634882
Signed-off-by: Kashyap Chamarthy <kchamart@redhat.com>
This commit is contained in:
Kashyap Chamarthy 2018-05-02 11:40:46 +02:00
parent be135bda38
commit 8fafbb30a1
2 changed files with 0 additions and 9 deletions

View File

@ -2077,10 +2077,6 @@ class LibguestfsCannotReadKernel(Invalid):
msg_fmt = _("Libguestfs does not have permission to read host kernel.")
class RealtimePolicyNotSupported(Invalid):
msg_fmt = _("Realtime policy not supported by hypervisor")
class RealtimeMaskNotFoundOrInvalid(Invalid):
msg_fmt = _("Realtime policy needs vCPU(s) mask configured with at least "
"1 RT vCPU and 1 ordinary vCPU. See hw:cpu_realtime_mask "

View File

@ -256,9 +256,6 @@ QEMU_MAX_SERIAL_PORTS = 4
# Qemu supports 4 serial consoles, we remove 1 because of the PTY one defined
ALLOWED_QEMU_SERIAL_PORTS = QEMU_MAX_SERIAL_PORTS - 1
# realtime support
MIN_LIBVIRT_REALTIME_VERSION = (1, 2, 13)
# libvirt postcopy support
MIN_LIBVIRT_POSTCOPY_VERSION = (1, 3, 3)
@ -4396,8 +4393,6 @@ class LibvirtDriver(driver.ComputeDriver):
vcpus_rt = set([])
wants_realtime = hardware.is_realtime_enabled(flavor)
if wants_realtime:
if not self._host.has_min_version(MIN_LIBVIRT_REALTIME_VERSION):
raise exception.RealtimePolicyNotSupported()
vcpus_rt = hardware.vcpus_realtime_topology(flavor, image_meta)
vcpusched = vconfig.LibvirtConfigGuestCPUTuneVCPUSched()
designer.set_vcpu_realtime_scheduler(