diff --git a/SOURCES/0001-Differentiate-between-vserver-host-and-guest.patch b/SOURCES/0001-Differentiate-between-vserver-host-and-guest.patch index 3b472f5..f108fc4 100644 --- a/SOURCES/0001-Differentiate-between-vserver-host-and-guest.patch +++ b/SOURCES/0001-Differentiate-between-vserver-host-and-guest.patch @@ -1,7 +1,7 @@ From d409914d13b88541402fe871d70e3dff9d738455 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Elan=20Ruusam=C3=A4e?= Date: Mon, 2 Sep 2013 15:24:11 +0100 -Subject: [PATCH 01/26] Differentiate between vserver host and guest. +Subject: [PATCH 01/27] Differentiate between vserver host and guest. RWMJ: Update documentation and tests. --- @@ -68,5 +68,5 @@ index 98cd4af..bff2998 100644 This process is running in a Linux LXC container. -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0002-Detect-new-Xen-VMs-RHBZ-973663.patch b/SOURCES/0002-Detect-new-Xen-VMs-RHBZ-973663.patch index 9bb52cd..863b257 100644 --- a/SOURCES/0002-Detect-new-Xen-VMs-RHBZ-973663.patch +++ b/SOURCES/0002-Detect-new-Xen-VMs-RHBZ-973663.patch @@ -1,7 +1,7 @@ From acd6bec92a99550ad98011d44f6381fdf7fa5992 Mon Sep 17 00:00:00 2001 From: nodata Date: Mon, 2 Sep 2013 16:59:32 +0100 -Subject: [PATCH 02/26] Detect new Xen VMs (RHBZ#973663). +Subject: [PATCH 02/27] Detect new Xen VMs (RHBZ#973663). --- virt-what.in | 2 +- @@ -21,5 +21,5 @@ index 422f6d0..bf663aa 100644 if grep -q "control_d" "${root}/proc/xen/capabilities"; then echo xen-dom0 -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0003-xen-Don-t-emit-warning-message-if-proc-xen-capabilit.patch b/SOURCES/0003-xen-Don-t-emit-warning-message-if-proc-xen-capabilit.patch index 8269fb0..5435cb2 100644 --- a/SOURCES/0003-xen-Don-t-emit-warning-message-if-proc-xen-capabilit.patch +++ b/SOURCES/0003-xen-Don-t-emit-warning-message-if-proc-xen-capabilit.patch @@ -1,7 +1,7 @@ From 8709c0e87dc3124b1a64d85654d6d4904702d767 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Mon, 28 Oct 2013 11:09:24 +0000 -Subject: [PATCH 03/26] xen: Don't emit warning message if +Subject: [PATCH 03/27] xen: Don't emit warning message if /proc/xen/capabilities file does not exist. On Amazon EC2: @@ -31,5 +31,5 @@ index bf663aa..4b6d3b8 100644 else echo xen-domU -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0004-Fix-various-typos-and-mistakes-in-comments.patch b/SOURCES/0004-Fix-various-typos-and-mistakes-in-comments.patch index eeeabf7..6d36b37 100644 --- a/SOURCES/0004-Fix-various-typos-and-mistakes-in-comments.patch +++ b/SOURCES/0004-Fix-various-typos-and-mistakes-in-comments.patch @@ -1,7 +1,7 @@ From 9709c8f01ec3e2f78bcaa07045343de249d7618d Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 12 Dec 2013 08:47:37 +0000 -Subject: [PATCH 04/26] Fix various typos and mistakes in comments. +Subject: [PATCH 04/27] Fix various typos and mistakes in comments. (Thanks Robert P. J. Day) --- @@ -38,5 +38,5 @@ index 4b6d3b8..fb399be 100644 prefix=@prefix@ exec_prefix=@exec_prefix@ -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0005-Fix-spelling-mistake-in-the-man-page-RHBZ-1099289.patch b/SOURCES/0005-Fix-spelling-mistake-in-the-man-page-RHBZ-1099289.patch index 0c235f5..46dc5e5 100644 --- a/SOURCES/0005-Fix-spelling-mistake-in-the-man-page-RHBZ-1099289.patch +++ b/SOURCES/0005-Fix-spelling-mistake-in-the-man-page-RHBZ-1099289.patch @@ -1,7 +1,7 @@ From cc494d23a60c699bdc843ecb9d3564e69aae006c Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 20 May 2014 10:50:39 +0100 -Subject: [PATCH 05/26] Fix spelling mistake in the man page (RHBZ#1099289). +Subject: [PATCH 05/27] Fix spelling mistake in the man page (RHBZ#1099289). --- virt-what.pod | 2 +- @@ -21,5 +21,5 @@ index bff2998..bcafd26 100644 =item B -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0006-Added-check-and-test-routines-for-Docker.patch b/SOURCES/0006-Added-check-and-test-routines-for-Docker.patch index c620fd6..5253672 100644 --- a/SOURCES/0006-Added-check-and-test-routines-for-Docker.patch +++ b/SOURCES/0006-Added-check-and-test-routines-for-Docker.patch @@ -1,7 +1,7 @@ From 89765910064584ebaea7a9899838a2cb66740d26 Mon Sep 17 00:00:00 2001 From: Charles Nguyen Date: Sat, 21 Jun 2014 22:27:51 -0500 -Subject: [PATCH 06/26] Added check and test routines for Docker +Subject: [PATCH 06/27] Added check and test routines for Docker --- Makefile.am | 7 +++++++ @@ -138,5 +138,5 @@ index fb399be..c04203e 100644 + echo docker +fi -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0007-Added-documentation-for-Docker-tests.patch b/SOURCES/0007-Added-documentation-for-Docker-tests.patch index 50b9918..625f8e0 100644 --- a/SOURCES/0007-Added-documentation-for-Docker-tests.patch +++ b/SOURCES/0007-Added-documentation-for-Docker-tests.patch @@ -1,7 +1,7 @@ From aab6a7d67b4e3bb1f9697ded4dba8bc0c16d32fa Mon Sep 17 00:00:00 2001 From: Charles Nguyen Date: Sat, 21 Jun 2014 23:43:05 -0500 -Subject: [PATCH 07/26] Added documentation for Docker tests +Subject: [PATCH 07/27] Added documentation for Docker tests --- virt-what.pod | 6 ++++++ @@ -25,5 +25,5 @@ index bcafd26..8fd9bc4 100644 This is Microsoft Hyper-V hypervisor. -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0008-virt-what.in-remove-bash-ism.patch b/SOURCES/0008-virt-what.in-remove-bash-ism.patch index 766fdcd..2e7628e 100644 --- a/SOURCES/0008-virt-what.in-remove-bash-ism.patch +++ b/SOURCES/0008-virt-what.in-remove-bash-ism.patch @@ -1,7 +1,7 @@ From 8769b28cce8fdbc7da0605b061242b9dba51fc20 Mon Sep 17 00:00:00 2001 From: "A. Gordon" Date: Mon, 15 Sep 2014 14:48:23 -0400 -Subject: [PATCH 08/26] virt-what.in: remove bash-ism +Subject: [PATCH 08/27] virt-what.in: remove bash-ism Use '/bin/sh' instead of '/bin/bash', with POSIX-compatible function definitions. @@ -35,5 +35,5 @@ index c04203e..1532b90 100644 echo "Options:" echo " --help Display this help" -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0009-virt-what.in-get-effective-uid-in-a-portable-way.patch b/SOURCES/0009-virt-what.in-get-effective-uid-in-a-portable-way.patch index 6c010c3..3db5baa 100644 --- a/SOURCES/0009-virt-what.in-get-effective-uid-in-a-portable-way.patch +++ b/SOURCES/0009-virt-what.in-get-effective-uid-in-a-portable-way.patch @@ -1,7 +1,7 @@ From e1e79b9a988ab66f7ab673034488b42057621320 Mon Sep 17 00:00:00 2001 From: Assaf Gordon Date: Mon, 15 Sep 2014 18:58:19 +0000 -Subject: [PATCH 09/26] virt-what.in: get effective uid in a portable way +Subject: [PATCH 09/27] virt-what.in: get effective uid in a portable way $EUID is bash-specific. Use the POSIX-compatible 'id -u' instead. --- @@ -24,5 +24,5 @@ index 1532b90..3feeb60 100644 fi -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0010-virt-what.in-warn-about-missing-cpuid-virt-helper-pr.patch b/SOURCES/0010-virt-what.in-warn-about-missing-cpuid-virt-helper-pr.patch index d1a7971..ccc1045 100644 --- a/SOURCES/0010-virt-what.in-warn-about-missing-cpuid-virt-helper-pr.patch +++ b/SOURCES/0010-virt-what.in-warn-about-missing-cpuid-virt-helper-pr.patch @@ -1,7 +1,7 @@ From d3908f46427a9126742a70967cf787edfd37ab43 Mon Sep 17 00:00:00 2001 From: Assaf Gordon Date: Mon, 15 Sep 2014 19:08:20 +0000 -Subject: [PATCH 10/26] virt-what.in: warn about missing cpuid-virt helper +Subject: [PATCH 10/27] virt-what.in: warn about missing cpuid-virt helper program Try to find the binary program on the $PATH, and give informative error @@ -28,5 +28,5 @@ index 3feeb60..5ae1ccb 100644 # helper program to get this information. -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0011-virt-what.in-verify-files-exists-before-grepping-the.patch b/SOURCES/0011-virt-what.in-verify-files-exists-before-grepping-the.patch index 526e6b6..911b4a2 100644 --- a/SOURCES/0011-virt-what.in-verify-files-exists-before-grepping-the.patch +++ b/SOURCES/0011-virt-what.in-verify-files-exists-before-grepping-the.patch @@ -1,7 +1,7 @@ From 960e513f430170bb58d59dcb26951f879a9baa7b Mon Sep 17 00:00:00 2001 From: Assaf Gordon Date: Mon, 15 Sep 2014 19:15:19 +0000 -Subject: [PATCH 11/26] virt-what.in: verify files exists before grepping them +Subject: [PATCH 11/27] virt-what.in: verify files exists before grepping them Don't grep linux-specific files (e.g. /proc/cpuinfo) unless they exist. This avoids extraneous errors on BSD/Hurd systems which don't have these @@ -61,5 +61,5 @@ index 5ae1ccb..6e9aef1 100644 if [ -f "${root}/proc/sysinfo" ]; then if grep -q 'VM.*Control Program.*z/VM' "${root}/proc/sysinfo"; then -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0012-virt-what.in-make-option-processing-portable.patch b/SOURCES/0012-virt-what.in-make-option-processing-portable.patch index 935c8fd..cc31caf 100644 --- a/SOURCES/0012-virt-what.in-make-option-processing-portable.patch +++ b/SOURCES/0012-virt-what.in-make-option-processing-portable.patch @@ -1,7 +1,7 @@ From 5d4106eafd7f2f6e71a1d0d90ebf4f4e766b772d Mon Sep 17 00:00:00 2001 From: Assaf Gordon Date: Mon, 15 Sep 2014 19:34:06 +0000 -Subject: [PATCH 12/26] virt-what.in: make option processing portable +Subject: [PATCH 12/27] virt-what.in: make option processing portable Replace linux-specific 'getopt' usage with manual option parsing. Because the used option are version simple (help/version) and the only @@ -48,5 +48,5 @@ index 6e9aef1..f2c0b90 100644 # Add /sbin and /usr/sbin to the path so we can find system # binaries like dmidecode. -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0013-build-use-portable-Makefile-variables.patch b/SOURCES/0013-build-use-portable-Makefile-variables.patch index 5592a14..c228f00 100644 --- a/SOURCES/0013-build-use-portable-Makefile-variables.patch +++ b/SOURCES/0013-build-use-portable-Makefile-variables.patch @@ -1,7 +1,7 @@ From b53bdd3ebadab879f161e0e4b881c79cb977e0e0 Mon Sep 17 00:00:00 2001 From: "A. Gordon" Date: Mon, 15 Sep 2014 15:51:50 -0400 -Subject: [PATCH 13/26] build: use portable Makefile variables +Subject: [PATCH 13/27] build: use portable Makefile variables * Makefile.am: use '$?' instead of '$<' $< in a non-inference rule is a GNU-make extension, which fails with @@ -27,5 +27,5 @@ index 24d1730..1c14948 100644 endif -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0014-Add-space-before-parens-in-function-defns-for-readab.patch b/SOURCES/0014-Add-space-before-parens-in-function-defns-for-readab.patch index 900e0b2..fc5ddff 100644 --- a/SOURCES/0014-Add-space-before-parens-in-function-defns-for-readab.patch +++ b/SOURCES/0014-Add-space-before-parens-in-function-defns-for-readab.patch @@ -1,7 +1,7 @@ From 35852eafd298e27b9388b80ec018ffb1249f8538 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 16 Sep 2014 19:02:18 +0100 -Subject: [PATCH 14/26] Add space before parens in function defns for +Subject: [PATCH 14/27] Add space before parens in function defns for readability. --- @@ -33,5 +33,5 @@ index f2c0b90..0770070 100644 echo "Options:" echo " --help Display this help" -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0015-Add-lkvm-detection.patch b/SOURCES/0015-Add-lkvm-detection.patch index b85f8db..7fc927e 100644 --- a/SOURCES/0015-Add-lkvm-detection.patch +++ b/SOURCES/0015-Add-lkvm-detection.patch @@ -1,7 +1,7 @@ From 33277fafa3892b27d3d265863d33e89ac2eea55e Mon Sep 17 00:00:00 2001 From: Andrew Jones Date: Fri, 27 Mar 2015 21:18:59 +0100 -Subject: [PATCH 15/26] Add lkvm detection +Subject: [PATCH 15/27] Add lkvm detection Signed-off-by: Andrew Jones --- @@ -233,5 +233,5 @@ index 8fd9bc4..0e2e8a5 100644 The guest appears to be running inside an OpenVZ or Virtuozzo -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0016-Add-ARM-support.patch b/SOURCES/0016-Add-ARM-support.patch index 6d4d75f..22ebbe7 100644 --- a/SOURCES/0016-Add-ARM-support.patch +++ b/SOURCES/0016-Add-ARM-support.patch @@ -1,7 +1,7 @@ From b87a2d79ce8c5eee3a2f945b8eb00d893104fd10 Mon Sep 17 00:00:00 2001 From: Andrew Jones Date: Fri, 27 Mar 2015 21:19:00 +0100 -Subject: [PATCH 16/26] Add ARM support +Subject: [PATCH 16/27] Add ARM support Currently only detects LKVM, QEMU/KVM, and Xen. Also only works if the guest is booted with DT (which is the only way that currently @@ -732,5 +732,5 @@ index ed08dae..a5ed33e 100644 fi -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0017-xen-arm-Fix-path-in-EXTRA_DIST.patch b/SOURCES/0017-xen-arm-Fix-path-in-EXTRA_DIST.patch index fbfb152..5a9890b 100644 --- a/SOURCES/0017-xen-arm-Fix-path-in-EXTRA_DIST.patch +++ b/SOURCES/0017-xen-arm-Fix-path-in-EXTRA_DIST.patch @@ -1,7 +1,7 @@ From ac098dd1513370145f10d6dd7c147b45168ef6a0 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 21 Apr 2015 12:12:45 +0100 -Subject: [PATCH 17/26] xen-arm: Fix path in EXTRA_DIST. +Subject: [PATCH 17/27] xen-arm: Fix path in EXTRA_DIST. --- Makefile.am | 2 +- @@ -21,5 +21,5 @@ index 514d229..8a47e96 100644 tests/xen-arm/sbin/dmidecode \ tests/xen-arm/sbin/uname \ -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0018-Update-copyright-years.patch b/SOURCES/0018-Update-copyright-years.patch index 69b13c6..6aa3344 100644 --- a/SOURCES/0018-Update-copyright-years.patch +++ b/SOURCES/0018-Update-copyright-years.patch @@ -1,7 +1,7 @@ From e70023e026f0abd820e9702f7a3c745e03c2846d Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Mon, 3 Aug 2015 12:23:05 +0100 -Subject: [PATCH 18/26] Update copyright years. +Subject: [PATCH 18/27] Update copyright years. --- virt-what.in | 2 +- @@ -34,5 +34,5 @@ index 0e2e8a5..d936e4a 100644 This program is free software; you can redistribute it and/or modify -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0019-Add-QEMU-KVM-detection-for-ACPI-boot-ARM.patch b/SOURCES/0019-Add-QEMU-KVM-detection-for-ACPI-boot-ARM.patch index 4b47e68..84d03a5 100644 --- a/SOURCES/0019-Add-QEMU-KVM-detection-for-ACPI-boot-ARM.patch +++ b/SOURCES/0019-Add-QEMU-KVM-detection-for-ACPI-boot-ARM.patch @@ -1,7 +1,7 @@ From c722083f37e514f4d8b9f9470536dcbae428631a Mon Sep 17 00:00:00 2001 From: Andrew Jones Date: Tue, 22 Sep 2015 15:54:55 +0200 -Subject: [PATCH 19/26] Add QEMU/KVM detection for ACPI-boot ARM +Subject: [PATCH 19/27] Add QEMU/KVM detection for ACPI-boot ARM Detect QEMU/KVM on ARM guests that have been boot with ACPI, i.e. without device tree. When boot with ACPI SMBIOS is populated, so we @@ -385,5 +385,5 @@ index 6daba34..697595c 100644 else # XXX This is known to fail for qemu with the explicit -cpu -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0020-trivial-comment-fixup.patch b/SOURCES/0020-trivial-comment-fixup.patch index 8e492ad..a3364fb 100644 --- a/SOURCES/0020-trivial-comment-fixup.patch +++ b/SOURCES/0020-trivial-comment-fixup.patch @@ -1,7 +1,7 @@ From fd9a0ea54fa254f880039a64f0ae68da1a5af1ff Mon Sep 17 00:00:00 2001 From: Andrew Jones Date: Tue, 22 Sep 2015 18:29:08 +0200 -Subject: [PATCH 20/26] trivial: comment fixup +Subject: [PATCH 20/27] trivial: comment fixup dmidecode does now exist on non-PC architectures. --- @@ -26,5 +26,5 @@ index 697595c..2de040a 100644 dmi=$(LANG=C dmidecode 2>&1) -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0021-Add-oVirt-RHBZ-1249438.patch b/SOURCES/0021-Add-oVirt-RHBZ-1249438.patch index 030ba56..07ec57d 100644 --- a/SOURCES/0021-Add-oVirt-RHBZ-1249438.patch +++ b/SOURCES/0021-Add-oVirt-RHBZ-1249438.patch @@ -1,7 +1,7 @@ From 74d099109217f7a4c0ec9790c6e83df392f4a5ae Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Mon, 3 Aug 2015 12:23:13 +0100 -Subject: [PATCH 21/26] Add oVirt (RHBZ#1249438). +Subject: [PATCH 21/27] Add oVirt (RHBZ#1249438). --- virt-what.in | 5 +++++ @@ -42,5 +42,5 @@ index d936e4a..4e38414 100644 The guest is running inside Parallels Virtual Platform -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0022-trivial-virt-what.in-doesn-t-use-tabs.patch b/SOURCES/0022-trivial-virt-what.in-doesn-t-use-tabs.patch index 0406ca1..8cf7080 100644 --- a/SOURCES/0022-trivial-virt-what.in-doesn-t-use-tabs.patch +++ b/SOURCES/0022-trivial-virt-what.in-doesn-t-use-tabs.patch @@ -1,7 +1,7 @@ From 4b9101e34d9e5f9c05131161a9702cf1f37e4792 Mon Sep 17 00:00:00 2001 From: Andrew Jones Date: Tue, 27 Oct 2015 18:16:02 +0100 -Subject: [PATCH 22/26] trivial: virt-what.in doesn't use tabs +Subject: [PATCH 22/27] trivial: virt-what.in doesn't use tabs --- virt-what.in | 18 +++++++++--------- @@ -67,5 +67,5 @@ index d37da85..2c2e6ac 100644 + echo docker fi -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0023-qemu-kvm-try-dmidecode-on-all-targets.patch b/SOURCES/0023-qemu-kvm-try-dmidecode-on-all-targets.patch index e360296..7c52960 100644 --- a/SOURCES/0023-qemu-kvm-try-dmidecode-on-all-targets.patch +++ b/SOURCES/0023-qemu-kvm-try-dmidecode-on-all-targets.patch @@ -1,39 +1,27 @@ From 8bc06c4843dc0b824e211b6f9f6f358336988b64 Mon Sep 17 00:00:00 2001 From: Andrew Jones Date: Tue, 27 Oct 2015 18:16:03 +0100 -Subject: [PATCH 23/26] qemu/kvm: try dmidecode on all targets +Subject: [PATCH 23/27] qemu/kvm: try dmidecode on all targets Looking at "$dmi" on targets that don't support dmidecode is harmless. Furthermore it works, not only for arm targets, but also pc, so move it out of the 'if arm' block. --- - Makefile.am | 12 +- - tests/qemu-arm-acpi/proc/cpuinfo | 63 ----------- - tests/qemu-arm-acpi/proc/self/status | 41 ------- - tests/qemu-arm-acpi/sbin/dmidecode | 141 ------------------------ - tests/qemu-arm-acpi/sbin/uname | 2 - - tests/qemu-arm-acpi/sbin/virt-what-cpuid-helper | 2 - - tests/qemu-smbios/proc/cpuinfo | 63 +++++++++++ - tests/qemu-smbios/proc/self/status | 41 +++++++ - tests/qemu-smbios/sbin/dmidecode | 141 ++++++++++++++++++++++++ - tests/qemu-smbios/sbin/uname | 2 + - tests/qemu-smbios/sbin/virt-what-cpuid-helper | 2 + - tests/test-qemu-arm-acpi.sh | 34 ------ - tests/test-qemu-smbios.sh | 34 ++++++ - virt-what.in | 10 +- - 14 files changed, 294 insertions(+), 294 deletions(-) - delete mode 100644 tests/qemu-arm-acpi/proc/cpuinfo - delete mode 100644 tests/qemu-arm-acpi/proc/self/status - delete mode 100755 tests/qemu-arm-acpi/sbin/dmidecode - delete mode 100755 tests/qemu-arm-acpi/sbin/uname - delete mode 100755 tests/qemu-arm-acpi/sbin/virt-what-cpuid-helper - create mode 100644 tests/qemu-smbios/proc/cpuinfo - create mode 100644 tests/qemu-smbios/proc/self/status - create mode 100755 tests/qemu-smbios/sbin/dmidecode - create mode 100755 tests/qemu-smbios/sbin/uname - create mode 100755 tests/qemu-smbios/sbin/virt-what-cpuid-helper - delete mode 100755 tests/test-qemu-arm-acpi.sh - create mode 100755 tests/test-qemu-smbios.sh + Makefile.am | 12 ++++++------ + tests/{qemu-arm-acpi => qemu-smbios}/proc/cpuinfo | 0 + tests/{qemu-arm-acpi => qemu-smbios}/proc/self/status | 0 + tests/{qemu-arm-acpi => qemu-smbios}/sbin/dmidecode | 0 + tests/{qemu-arm-acpi => qemu-smbios}/sbin/uname | 0 + .../sbin/virt-what-cpuid-helper | 0 + tests/{test-qemu-arm-acpi.sh => test-qemu-smbios.sh} | 2 +- + virt-what.in | 10 +++++----- + 8 files changed, 12 insertions(+), 12 deletions(-) + rename tests/{qemu-arm-acpi => qemu-smbios}/proc/cpuinfo (100%) + rename tests/{qemu-arm-acpi => qemu-smbios}/proc/self/status (100%) + rename tests/{qemu-arm-acpi => qemu-smbios}/sbin/dmidecode (100%) + rename tests/{qemu-arm-acpi => qemu-smbios}/sbin/uname (100%) + rename tests/{qemu-arm-acpi => qemu-smbios}/sbin/virt-what-cpuid-helper (100%) + rename tests/{test-qemu-arm-acpi.sh => test-qemu-smbios.sh} (98%) diff --git a/Makefile.am b/Makefile.am index 2c958ca..0045bcb 100644 @@ -65,644 +53,42 @@ index 2c958ca..0045bcb 100644 tests/rhel5-xen-dom0/proc/cpuinfo \ tests/rhel5-xen-dom0/proc/self/status \ tests/rhel5-xen-dom0/proc/xen/balloon \ -diff --git a/tests/qemu-arm-acpi/proc/cpuinfo b/tests/qemu-arm-acpi/proc/cpuinfo -deleted file mode 100644 -index b83a182..0000000 ---- a/tests/qemu-arm-acpi/proc/cpuinfo -+++ /dev/null -@@ -1,63 +0,0 @@ --processor : 0 --Features : fp asimd evtstrm --CPU implementer : 0x50 --CPU architecture: 8 --CPU variant : 0x0 --CPU part : 0x000 --CPU revision : 0 -- --processor : 1 --Features : fp asimd evtstrm --CPU implementer : 0x50 --CPU architecture: 8 --CPU variant : 0x0 --CPU part : 0x000 --CPU revision : 0 -- --processor : 2 --Features : fp asimd evtstrm --CPU implementer : 0x50 --CPU architecture: 8 --CPU variant : 0x0 --CPU part : 0x000 --CPU revision : 0 -- --processor : 3 --Features : fp asimd evtstrm --CPU implementer : 0x50 --CPU architecture: 8 --CPU variant : 0x0 --CPU part : 0x000 --CPU revision : 0 -- --processor : 4 --Features : fp asimd evtstrm --CPU implementer : 0x50 --CPU architecture: 8 --CPU variant : 0x0 --CPU part : 0x000 --CPU revision : 0 -- --processor : 5 --Features : fp asimd evtstrm --CPU implementer : 0x50 --CPU architecture: 8 --CPU variant : 0x0 --CPU part : 0x000 --CPU revision : 0 -- --processor : 6 --Features : fp asimd evtstrm --CPU implementer : 0x50 --CPU architecture: 8 --CPU variant : 0x0 --CPU part : 0x000 --CPU revision : 0 -- --processor : 7 --Features : fp asimd evtstrm --CPU implementer : 0x50 --CPU architecture: 8 --CPU variant : 0x0 --CPU part : 0x000 --CPU revision : 0 -diff --git a/tests/qemu-arm-acpi/proc/self/status b/tests/qemu-arm-acpi/proc/self/status -deleted file mode 100644 -index 751f5e7..0000000 ---- a/tests/qemu-arm-acpi/proc/self/status -+++ /dev/null -@@ -1,41 +0,0 @@ --Name: cat --State: R (running) --Tgid: 8307 --Ngid: 0 --Pid: 8307 --PPid: 1415 --TracerPid: 0 --Uid: 0 0 0 0 --Gid: 0 0 0 0 --FDSize: 256 --Groups: --VmPeak: 109696 kB --VmSize: 109696 kB --VmLck: 0 kB --VmPin: 0 kB --VmHWM: 832 kB --VmRSS: 832 kB --VmData: 320 kB --VmStk: 256 kB --VmExe: 64 kB --VmLib: 1536 kB --VmPTE: 192 kB --VmSwap: 0 kB --Threads: 1 --SigQ: 0/5821 --SigPnd: 0000000000000000 --ShdPnd: 0000000000000000 --SigBlk: 0000000000000000 --SigIgn: 0000000000000000 --SigCgt: 0000000000000000 --CapInh: 0000000000000000 --CapPrm: 0000003fffffffff --CapEff: 0000003fffffffff --CapBnd: 0000003fffffffff --Seccomp: 0 --Cpus_allowed: ff --Cpus_allowed_list: 0-7 --Mems_allowed: 1 --Mems_allowed_list: 0 --voluntary_ctxt_switches: 1 --nonvoluntary_ctxt_switches: 1 -diff --git a/tests/qemu-arm-acpi/sbin/dmidecode b/tests/qemu-arm-acpi/sbin/dmidecode -deleted file mode 100755 -index f7ffd4b..0000000 ---- a/tests/qemu-arm-acpi/sbin/dmidecode -+++ /dev/null -@@ -1,141 +0,0 @@ --#!/bin/sh - --cat <<'EOF' --# dmidecode 3.0 --Getting SMBIOS data from sysfs. --SMBIOS 3.0.0 present. --Table at 0x136650000. -- --Handle 0x0100, DMI type 1, 27 bytes --System Information -- Manufacturer: QEMU -- Product Name: QEMU Virtual Machine -- Version: 1.0 -- Serial Number: Not Specified -- UUID: 6EB70381-DF9C-4407-B6AB-9FA4452117EA -- Wake-up Type: Power Switch -- SKU Number: Not Specified -- Family: Red Hat Enterprise Linux -- --Handle 0x0300, DMI type 3, 21 bytes --Chassis Information -- Manufacturer: QEMU -- Type: Other -- Lock: Not Present -- Version: 1.0 -- Serial Number: Not Specified -- Asset Tag: Not Specified -- Boot-up State: Safe -- Power Supply State: Safe -- Thermal State: Safe -- Security Status: Unknown -- OEM Information: 0x00000000 -- Height: Unspecified -- Number Of Power Cords: Unspecified -- Contained Elements: 0 -- --Handle 0x0400, DMI type 4, 42 bytes --Processor Information -- Socket Designation: CPU 0 -- Type: Central Processor -- Family: Other -- Manufacturer: QEMU -- ID: 00 00 00 00 00 00 00 00 -- Version: 1.0 -- Voltage: Unknown -- External Clock: Unknown -- Max Speed: 2000 MHz -- Current Speed: 2000 MHz -- Status: Populated, Enabled -- Upgrade: Other -- L1 Cache Handle: Not Provided -- L2 Cache Handle: Not Provided -- L3 Cache Handle: Not Provided -- Serial Number: Not Specified -- Asset Tag: Not Specified -- Part Number: Not Specified -- Core Count: 1 -- Core Enabled: 1 -- Thread Count: 1 -- Characteristics: None -- --Handle 0x0401, DMI type 4, 42 bytes --Processor Information -- Socket Designation: CPU 1 -- Type: Central Processor -- Family: Other -- Manufacturer: QEMU -- ID: 00 00 00 00 00 00 00 00 -- Version: 1.0 -- Voltage: Unknown -- External Clock: Unknown -- Max Speed: 2000 MHz -- Current Speed: 2000 MHz -- Status: Populated, Enabled -- Upgrade: Other -- L1 Cache Handle: Not Provided -- L2 Cache Handle: Not Provided -- L3 Cache Handle: Not Provided -- Serial Number: Not Specified -- Asset Tag: Not Specified -- Part Number: Not Specified -- Core Count: 1 -- Core Enabled: 1 -- Thread Count: 1 -- Characteristics: None -- --Handle 0x1000, DMI type 16, 23 bytes --Physical Memory Array -- Location: Other -- Use: System Memory -- Error Correction Type: Multi-bit ECC -- Maximum Capacity: 4 GB -- Error Information Handle: Not Provided -- Number Of Devices: 1 -- --Handle 0x1100, DMI type 17, 40 bytes --Memory Device -- Array Handle: 0x1000 -- Error Information Handle: Not Provided -- Total Width: Unknown -- Data Width: Unknown -- Size: 4096 MB -- Form Factor: DIMM -- Set: None -- Locator: DIMM 0 -- Bank Locator: Not Specified -- Type: RAM -- Type Detail: Other -- Speed: Unknown -- Manufacturer: QEMU -- Serial Number: Not Specified -- Asset Tag: Not Specified -- Part Number: Not Specified -- Rank: Unknown -- Configured Clock Speed: Unknown -- Minimum Voltage: Unknown -- Maximum Voltage: Unknown -- Configured Voltage: Unknown -- --Handle 0x2000, DMI type 32, 11 bytes --System Boot Information -- Status: No errors detected -- --Handle 0x0000, DMI type 0, 24 bytes --BIOS Information -- Vendor: EFI Development Kit II / OVMF -- Version: 0.0.0 -- Release Date: 02/06/2015 -- Address: 0xE8000 -- Runtime Size: 96 kB -- ROM Size: 64 kB -- Characteristics: -- BIOS characteristics not supported -- Targeted content distribution is supported -- UEFI is supported -- System is a virtual machine -- BIOS Revision: 0.0 -- --Handle 0xFEFF, DMI type 127, 4 bytes --End Of Table -- --EOF -diff --git a/tests/qemu-arm-acpi/sbin/uname b/tests/qemu-arm-acpi/sbin/uname -deleted file mode 100755 -index bd33a2d..0000000 ---- a/tests/qemu-arm-acpi/sbin/uname -+++ /dev/null -@@ -1,2 +0,0 @@ --#!/bin/sh - --echo aarch64 -diff --git a/tests/qemu-arm-acpi/sbin/virt-what-cpuid-helper b/tests/qemu-arm-acpi/sbin/virt-what-cpuid-helper -deleted file mode 100755 -index 77a6692..0000000 ---- a/tests/qemu-arm-acpi/sbin/virt-what-cpuid-helper -+++ /dev/null -@@ -1,2 +0,0 @@ --#!/bin/sh - --# nothing -diff --git a/tests/qemu-smbios/proc/cpuinfo b/tests/qemu-smbios/proc/cpuinfo -new file mode 100644 -index 0000000..b83a182 ---- /dev/null -+++ b/tests/qemu-smbios/proc/cpuinfo -@@ -0,0 +1,63 @@ -+processor : 0 -+Features : fp asimd evtstrm -+CPU implementer : 0x50 -+CPU architecture: 8 -+CPU variant : 0x0 -+CPU part : 0x000 -+CPU revision : 0 -+ -+processor : 1 -+Features : fp asimd evtstrm -+CPU implementer : 0x50 -+CPU architecture: 8 -+CPU variant : 0x0 -+CPU part : 0x000 -+CPU revision : 0 -+ -+processor : 2 -+Features : fp asimd evtstrm -+CPU implementer : 0x50 -+CPU architecture: 8 -+CPU variant : 0x0 -+CPU part : 0x000 -+CPU revision : 0 -+ -+processor : 3 -+Features : fp asimd evtstrm -+CPU implementer : 0x50 -+CPU architecture: 8 -+CPU variant : 0x0 -+CPU part : 0x000 -+CPU revision : 0 -+ -+processor : 4 -+Features : fp asimd evtstrm -+CPU implementer : 0x50 -+CPU architecture: 8 -+CPU variant : 0x0 -+CPU part : 0x000 -+CPU revision : 0 -+ -+processor : 5 -+Features : fp asimd evtstrm -+CPU implementer : 0x50 -+CPU architecture: 8 -+CPU variant : 0x0 -+CPU part : 0x000 -+CPU revision : 0 -+ -+processor : 6 -+Features : fp asimd evtstrm -+CPU implementer : 0x50 -+CPU architecture: 8 -+CPU variant : 0x0 -+CPU part : 0x000 -+CPU revision : 0 -+ -+processor : 7 -+Features : fp asimd evtstrm -+CPU implementer : 0x50 -+CPU architecture: 8 -+CPU variant : 0x0 -+CPU part : 0x000 -+CPU revision : 0 -diff --git a/tests/qemu-smbios/proc/self/status b/tests/qemu-smbios/proc/self/status -new file mode 100644 -index 0000000..751f5e7 ---- /dev/null -+++ b/tests/qemu-smbios/proc/self/status -@@ -0,0 +1,41 @@ -+Name: cat -+State: R (running) -+Tgid: 8307 -+Ngid: 0 -+Pid: 8307 -+PPid: 1415 -+TracerPid: 0 -+Uid: 0 0 0 0 -+Gid: 0 0 0 0 -+FDSize: 256 -+Groups: -+VmPeak: 109696 kB -+VmSize: 109696 kB -+VmLck: 0 kB -+VmPin: 0 kB -+VmHWM: 832 kB -+VmRSS: 832 kB -+VmData: 320 kB -+VmStk: 256 kB -+VmExe: 64 kB -+VmLib: 1536 kB -+VmPTE: 192 kB -+VmSwap: 0 kB -+Threads: 1 -+SigQ: 0/5821 -+SigPnd: 0000000000000000 -+ShdPnd: 0000000000000000 -+SigBlk: 0000000000000000 -+SigIgn: 0000000000000000 -+SigCgt: 0000000000000000 -+CapInh: 0000000000000000 -+CapPrm: 0000003fffffffff -+CapEff: 0000003fffffffff -+CapBnd: 0000003fffffffff -+Seccomp: 0 -+Cpus_allowed: ff -+Cpus_allowed_list: 0-7 -+Mems_allowed: 1 -+Mems_allowed_list: 0 -+voluntary_ctxt_switches: 1 -+nonvoluntary_ctxt_switches: 1 -diff --git a/tests/qemu-smbios/sbin/dmidecode b/tests/qemu-smbios/sbin/dmidecode -new file mode 100755 -index 0000000..f7ffd4b ---- /dev/null -+++ b/tests/qemu-smbios/sbin/dmidecode -@@ -0,0 +1,141 @@ -+#!/bin/sh - -+cat <<'EOF' -+# dmidecode 3.0 -+Getting SMBIOS data from sysfs. -+SMBIOS 3.0.0 present. -+Table at 0x136650000. -+ -+Handle 0x0100, DMI type 1, 27 bytes -+System Information -+ Manufacturer: QEMU -+ Product Name: QEMU Virtual Machine -+ Version: 1.0 -+ Serial Number: Not Specified -+ UUID: 6EB70381-DF9C-4407-B6AB-9FA4452117EA -+ Wake-up Type: Power Switch -+ SKU Number: Not Specified -+ Family: Red Hat Enterprise Linux -+ -+Handle 0x0300, DMI type 3, 21 bytes -+Chassis Information -+ Manufacturer: QEMU -+ Type: Other -+ Lock: Not Present -+ Version: 1.0 -+ Serial Number: Not Specified -+ Asset Tag: Not Specified -+ Boot-up State: Safe -+ Power Supply State: Safe -+ Thermal State: Safe -+ Security Status: Unknown -+ OEM Information: 0x00000000 -+ Height: Unspecified -+ Number Of Power Cords: Unspecified -+ Contained Elements: 0 -+ -+Handle 0x0400, DMI type 4, 42 bytes -+Processor Information -+ Socket Designation: CPU 0 -+ Type: Central Processor -+ Family: Other -+ Manufacturer: QEMU -+ ID: 00 00 00 00 00 00 00 00 -+ Version: 1.0 -+ Voltage: Unknown -+ External Clock: Unknown -+ Max Speed: 2000 MHz -+ Current Speed: 2000 MHz -+ Status: Populated, Enabled -+ Upgrade: Other -+ L1 Cache Handle: Not Provided -+ L2 Cache Handle: Not Provided -+ L3 Cache Handle: Not Provided -+ Serial Number: Not Specified -+ Asset Tag: Not Specified -+ Part Number: Not Specified -+ Core Count: 1 -+ Core Enabled: 1 -+ Thread Count: 1 -+ Characteristics: None -+ -+Handle 0x0401, DMI type 4, 42 bytes -+Processor Information -+ Socket Designation: CPU 1 -+ Type: Central Processor -+ Family: Other -+ Manufacturer: QEMU -+ ID: 00 00 00 00 00 00 00 00 -+ Version: 1.0 -+ Voltage: Unknown -+ External Clock: Unknown -+ Max Speed: 2000 MHz -+ Current Speed: 2000 MHz -+ Status: Populated, Enabled -+ Upgrade: Other -+ L1 Cache Handle: Not Provided -+ L2 Cache Handle: Not Provided -+ L3 Cache Handle: Not Provided -+ Serial Number: Not Specified -+ Asset Tag: Not Specified -+ Part Number: Not Specified -+ Core Count: 1 -+ Core Enabled: 1 -+ Thread Count: 1 -+ Characteristics: None -+ -+Handle 0x1000, DMI type 16, 23 bytes -+Physical Memory Array -+ Location: Other -+ Use: System Memory -+ Error Correction Type: Multi-bit ECC -+ Maximum Capacity: 4 GB -+ Error Information Handle: Not Provided -+ Number Of Devices: 1 -+ -+Handle 0x1100, DMI type 17, 40 bytes -+Memory Device -+ Array Handle: 0x1000 -+ Error Information Handle: Not Provided -+ Total Width: Unknown -+ Data Width: Unknown -+ Size: 4096 MB -+ Form Factor: DIMM -+ Set: None -+ Locator: DIMM 0 -+ Bank Locator: Not Specified -+ Type: RAM -+ Type Detail: Other -+ Speed: Unknown -+ Manufacturer: QEMU -+ Serial Number: Not Specified -+ Asset Tag: Not Specified -+ Part Number: Not Specified -+ Rank: Unknown -+ Configured Clock Speed: Unknown -+ Minimum Voltage: Unknown -+ Maximum Voltage: Unknown -+ Configured Voltage: Unknown -+ -+Handle 0x2000, DMI type 32, 11 bytes -+System Boot Information -+ Status: No errors detected -+ -+Handle 0x0000, DMI type 0, 24 bytes -+BIOS Information -+ Vendor: EFI Development Kit II / OVMF -+ Version: 0.0.0 -+ Release Date: 02/06/2015 -+ Address: 0xE8000 -+ Runtime Size: 96 kB -+ ROM Size: 64 kB -+ Characteristics: -+ BIOS characteristics not supported -+ Targeted content distribution is supported -+ UEFI is supported -+ System is a virtual machine -+ BIOS Revision: 0.0 -+ -+Handle 0xFEFF, DMI type 127, 4 bytes -+End Of Table -+ -+EOF -diff --git a/tests/qemu-smbios/sbin/uname b/tests/qemu-smbios/sbin/uname -new file mode 100755 -index 0000000..bd33a2d ---- /dev/null -+++ b/tests/qemu-smbios/sbin/uname -@@ -0,0 +1,2 @@ -+#!/bin/sh - -+echo aarch64 -diff --git a/tests/qemu-smbios/sbin/virt-what-cpuid-helper b/tests/qemu-smbios/sbin/virt-what-cpuid-helper -new file mode 100755 -index 0000000..77a6692 ---- /dev/null -+++ b/tests/qemu-smbios/sbin/virt-what-cpuid-helper -@@ -0,0 +1,2 @@ -+#!/bin/sh - -+# nothing -diff --git a/tests/test-qemu-arm-acpi.sh b/tests/test-qemu-arm-acpi.sh -deleted file mode 100755 -index 64db9eb..0000000 +diff --git a/tests/qemu-arm-acpi/proc/cpuinfo b/tests/qemu-smbios/proc/cpuinfo +similarity index 100% +rename from tests/qemu-arm-acpi/proc/cpuinfo +rename to tests/qemu-smbios/proc/cpuinfo +diff --git a/tests/qemu-arm-acpi/proc/self/status b/tests/qemu-smbios/proc/self/status +similarity index 100% +rename from tests/qemu-arm-acpi/proc/self/status +rename to tests/qemu-smbios/proc/self/status +diff --git a/tests/qemu-arm-acpi/sbin/dmidecode b/tests/qemu-smbios/sbin/dmidecode +similarity index 100% +rename from tests/qemu-arm-acpi/sbin/dmidecode +rename to tests/qemu-smbios/sbin/dmidecode +diff --git a/tests/qemu-arm-acpi/sbin/uname b/tests/qemu-smbios/sbin/uname +similarity index 100% +rename from tests/qemu-arm-acpi/sbin/uname +rename to tests/qemu-smbios/sbin/uname +diff --git a/tests/qemu-arm-acpi/sbin/virt-what-cpuid-helper b/tests/qemu-smbios/sbin/virt-what-cpuid-helper +similarity index 100% +rename from tests/qemu-arm-acpi/sbin/virt-what-cpuid-helper +rename to tests/qemu-smbios/sbin/virt-what-cpuid-helper +diff --git a/tests/test-qemu-arm-acpi.sh b/tests/test-qemu-smbios.sh +similarity index 98% +rename from tests/test-qemu-arm-acpi.sh +rename to tests/test-qemu-smbios.sh +index 64db9eb..114470a 100755 --- a/tests/test-qemu-arm-acpi.sh -+++ /dev/null -@@ -1,34 +0,0 @@ --# Test for qemu on ARM --# Copyright (C) 2015 Red Hat Inc. --# --# This program is free software; you can redistribute it and/or modify --# it under the terms of the GNU General Public License as published by --# the Free Software Foundation; either version 2 of the License, or --# (at your option) any later version. --# --# This program is distributed in the hope that it will be useful, --# but WITHOUT ANY WARRANTY; without even the implied warranty of --# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the --# GNU General Public License for more details. --# --# You should have received a copy of the GNU General Public License --# along with this program; if not, write to the Free Software --# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -- --root=tests/qemu-arm-acpi -- --output="$(./virt-what --test-root=$root 2>&1)" --expected="qemu" -- --if [ "$output" != "$expected" ]; then -- echo "$0: test failed because output did not match expected" -- echo "Expected output was:" -- echo "----------------------------------------" -- echo "$expected" -- echo "----------------------------------------" -- echo "But the actual output of the program was:" -- echo "----------------------------------------" -- echo "$output" -- echo "----------------------------------------" -- exit 1 --fi -diff --git a/tests/test-qemu-smbios.sh b/tests/test-qemu-smbios.sh -new file mode 100755 -index 0000000..114470a ---- /dev/null +++ b/tests/test-qemu-smbios.sh -@@ -0,0 +1,34 @@ -+# Test for qemu on ARM -+# Copyright (C) 2015 Red Hat Inc. -+# -+# This program is free software; you can redistribute it and/or modify -+# it under the terms of the GNU General Public License as published by -+# the Free Software Foundation; either version 2 of the License, or -+# (at your option) any later version. -+# -+# This program is distributed in the hope that it will be useful, -+# but WITHOUT ANY WARRANTY; without even the implied warranty of -+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+# GNU General Public License for more details. -+# -+# You should have received a copy of the GNU General Public License -+# along with this program; if not, write to the Free Software -+# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -+ +@@ -15,7 +15,7 @@ + # along with this program; if not, write to the Free Software + # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + +-root=tests/qemu-arm-acpi +root=tests/qemu-smbios -+ -+output="$(./virt-what --test-root=$root 2>&1)" -+expected="qemu" -+ -+if [ "$output" != "$expected" ]; then -+ echo "$0: test failed because output did not match expected" -+ echo "Expected output was:" -+ echo "----------------------------------------" -+ echo "$expected" -+ echo "----------------------------------------" -+ echo "But the actual output of the program was:" -+ echo "----------------------------------------" -+ echo "$output" -+ echo "----------------------------------------" -+ exit 1 -+fi + + output="$(./virt-what --test-root=$root 2>&1)" + expected="qemu" diff --git a/virt-what.in b/virt-what.in index 2c2e6ac..355e438 100644 --- a/virt-what.in @@ -732,5 +118,5 @@ index 2c2e6ac..355e438 100644 else # XXX This is known to fail for qemu with the explicit -cpu -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0024-qemu-kvm-dmidecode-look-for-KVM.patch b/SOURCES/0024-qemu-kvm-dmidecode-look-for-KVM.patch index 91a0d08..6056ec1 100644 --- a/SOURCES/0024-qemu-kvm-dmidecode-look-for-KVM.patch +++ b/SOURCES/0024-qemu-kvm-dmidecode-look-for-KVM.patch @@ -1,7 +1,7 @@ From 8528efafcad59f0fde7e15860f19061c3af810fa Mon Sep 17 00:00:00 2001 From: Andrew Jones Date: Tue, 27 Oct 2015 18:16:04 +0100 -Subject: [PATCH 24/26] qemu/kvm: dmidecode: look for 'KVM' +Subject: [PATCH 24/27] qemu/kvm: dmidecode: look for 'KVM' We can check the product name for 'KVM' to determine if we're accelerated. This only works for arm/aarch64 targets boot with @@ -387,5 +387,5 @@ index 355e438..776bfde 100644 skip_lkvm=true elif [ "$arch" = "arm" ] || [ "$arch" = "aarch64" ]; then -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0025-Add-support-for-detecting-ppc64-LPAR-as-virt-guests.patch b/SOURCES/0025-Add-support-for-detecting-ppc64-LPAR-as-virt-guests.patch index e6148ea..d10dfed 100644 --- a/SOURCES/0025-Add-support-for-detecting-ppc64-LPAR-as-virt-guests.patch +++ b/SOURCES/0025-Add-support-for-detecting-ppc64-LPAR-as-virt-guests.patch @@ -1,7 +1,7 @@ From 0b7c28b283649783d011c059ef0321d349a0ce46 Mon Sep 17 00:00:00 2001 From: Adrian Likins Date: Mon, 20 Jun 2016 12:57:27 +0100 -Subject: [PATCH 25/26] Add support for detecting ppc64 LPAR as virt guests. +Subject: [PATCH 25/27] Add support for detecting ppc64 LPAR as virt guests. https://bugzilla.redhat.com/show_bug.cgi?id=1072524#c13 --- @@ -1599,5 +1599,5 @@ index 776bfde..a91845e 100644 + fi +fi -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0026-Update-the-previous-commit-to-use-system-virt-standa.patch b/SOURCES/0026-Update-the-previous-commit-to-use-system-virt-standa.patch index 118d1c2..23171b8 100644 --- a/SOURCES/0026-Update-the-previous-commit-to-use-system-virt-standa.patch +++ b/SOURCES/0026-Update-the-previous-commit-to-use-system-virt-standa.patch @@ -1,7 +1,7 @@ From b933eff4e7c86959a096f15e5372d4491e56a55b Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Mon, 20 Jun 2016 13:14:53 +0100 -Subject: [PATCH 26/26] Update the previous commit to use - +Subject: [PATCH 26/27] Update the previous commit to use - standard for facts. Also I renamed ppc64 to power, since that is the official IBM name. @@ -100,5 +100,5 @@ index 4e38414..fe9567f 100644 This is an IBM SystemZ (or other S/390) hardware partitioning system. -- -1.8.3.1 +2.10.2 diff --git a/SOURCES/0027-Add-detection-of-Red-Hat-Enterprise-Virtualization-h.patch b/SOURCES/0027-Add-detection-of-Red-Hat-Enterprise-Virtualization-h.patch new file mode 100644 index 0000000..e17ac2f --- /dev/null +++ b/SOURCES/0027-Add-detection-of-Red-Hat-Enterprise-Virtualization-h.patch @@ -0,0 +1,363 @@ +From 15b98e7d56cf8a0e40948db27f341c71640ab252 Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Mon, 22 Aug 2016 12:30:25 +0100 +Subject: [PATCH 27/27] Add detection of Red Hat Enterprise Virtualization + hypervisor (RHBZ#1249438). + +Thanks: Xianghua Chen +--- + Makefile.am | 6 ++ + tests/rhev/proc/cpuinfo | 26 +++++++ + tests/rhev/proc/self/status | 41 +++++++++++ + tests/rhev/sbin/dmidecode | 123 +++++++++++++++++++++++++++++++++ + tests/rhev/sbin/uname | 2 + + tests/rhev/sbin/virt-what-cpuid-helper | 2 + + tests/test-rhev.sh | 35 ++++++++++ + virt-what.in | 5 +- + virt-what.pod | 9 ++- + 9 files changed, 247 insertions(+), 2 deletions(-) + create mode 100644 tests/rhev/proc/cpuinfo + create mode 100644 tests/rhev/proc/self/status + create mode 100755 tests/rhev/sbin/dmidecode + create mode 100755 tests/rhev/sbin/uname + create mode 100755 tests/rhev/sbin/virt-what-cpuid-helper + create mode 100755 tests/test-rhev.sh + +diff --git a/Makefile.am b/Makefile.am +index 73dfc7b..d5ee027 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -63,6 +63,7 @@ TESTS = \ + tests/test-rhel5-xen-domU-hvm.sh \ + tests/test-rhel5-xen-domU-hvm-ia64.sh \ + tests/test-rhel5-xen-domU-pv.sh \ ++ tests/test-rhev.sh \ + tests/test-xen-arm.sh \ + tests/test-zvm.sh + +@@ -237,6 +238,11 @@ EXTRA_DIST = \ + tests/rhel5-xen-domU-pv/sys/hypervisor/compilation/compiled_by \ + tests/rhel5-xen-domU-pv/sys/hypervisor/compilation/compile_date \ + tests/rhel5-xen-domU-pv/sys/hypervisor/uuid \ ++ tests/rhev/proc/cpuinfo \ ++ tests/rhev/proc/self/status \ ++ tests/rhev/sbin/dmidecode \ ++ tests/rhev/sbin/uname \ ++ tests/rhev/sbin/virt-what-cpuid-helper \ + tests/xen-arm/proc/cpuinfo \ + tests/xen-arm/proc/device-tree/hypervisor/compatible \ + tests/xen-arm/proc/self/status \ +diff --git a/tests/rhev/proc/cpuinfo b/tests/rhev/proc/cpuinfo +new file mode 100644 +index 0000000..6dba878 +--- /dev/null ++++ b/tests/rhev/proc/cpuinfo +@@ -0,0 +1,26 @@ ++processor : 0 ++vendor_id : GenuineIntel ++cpu family : 6 ++model : 15 ++model name : Intel Celeron_4x0 (Conroe/Merom Class Core 2) ++stepping : 3 ++microcode : 0x1 ++cpu MHz : 3392.302 ++cache size : 4096 KB ++physical id : 0 ++siblings : 1 ++core id : 0 ++cpu cores : 1 ++apicid : 0 ++initial apicid : 0 ++fpu : yes ++fpu_exception : yes ++cpuid level : 10 ++wp : yes ++flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 syscall nx lm constant_tsc rep_good nopl pni ssse3 x2apic hypervisor lahf_lm ++bogomips : 6784.60 ++clflush size : 64 ++cache_alignment : 64 ++address sizes : 36 bits physical, 48 bits virtual ++power management: ++ +diff --git a/tests/rhev/proc/self/status b/tests/rhev/proc/self/status +new file mode 100644 +index 0000000..5d1fe13 +--- /dev/null ++++ b/tests/rhev/proc/self/status +@@ -0,0 +1,41 @@ ++Name: cat ++State: R (running) ++Tgid: 32687 ++Ngid: 0 ++Pid: 32687 ++PPid: 32670 ++TracerPid: 0 ++Uid: 0 0 0 0 ++Gid: 0 0 0 0 ++FDSize: 256 ++Groups: 0 ++VmPeak: 107916 kB ++VmSize: 107916 kB ++VmLck: 0 kB ++VmPin: 0 kB ++VmHWM: 348 kB ++VmRSS: 348 kB ++VmData: 180 kB ++VmStk: 136 kB ++VmExe: 44 kB ++VmLib: 1880 kB ++VmPTE: 44 kB ++VmSwap: 0 kB ++Threads: 1 ++SigQ: 0/3883 ++SigPnd: 0000000000000000 ++ShdPnd: 0000000000000000 ++SigBlk: 0000000000000000 ++SigIgn: 0000000000000000 ++SigCgt: 0000000000000000 ++CapInh: 0000000000000000 ++CapPrm: 0000001fffffffff ++CapEff: 0000001fffffffff ++CapBnd: 0000001fffffffff ++Seccomp: 0 ++Cpus_allowed: ffff ++Cpus_allowed_list: 0-15 ++Mems_allowed: 00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001 ++Mems_allowed_list: 0 ++voluntary_ctxt_switches: 0 ++nonvoluntary_ctxt_switches: 0 +diff --git a/tests/rhev/sbin/dmidecode b/tests/rhev/sbin/dmidecode +new file mode 100755 +index 0000000..d44f172 +--- /dev/null ++++ b/tests/rhev/sbin/dmidecode +@@ -0,0 +1,123 @@ ++#!/bin/sh - ++cat <<'EOF' ++# dmidecode 3.0 ++Scanning /dev/mem for entry point. ++SMBIOS 2.8 present. ++9 structures occupying 481 bytes. ++Table at 0x000F1D20. ++ ++Handle 0x0000, DMI type 0, 24 bytes ++BIOS Information ++ Vendor: SeaBIOS ++ Version: seabios-1.7.5-11.el7 ++ Release Date: 04/01/2014 ++ Address: 0xE8000 ++ Runtime Size: 96 kB ++ ROM Size: 64 kB ++ Characteristics: ++ BIOS characteristics not supported ++ Targeted content distribution is supported ++ BIOS Revision: 0.0 ++ ++Handle 0x0100, DMI type 1, 27 bytes ++System Information ++ Manufacturer: Red Hat ++ Product Name: RHEV Hypervisor ++ Version: 4.0-2.el7 ++ Serial Number: 4C4C4544-004C-4B10-8036-C7C04F4A5931 ++ UUID: 469665C0-69F7-436B-BBF3-6632988BEDC8 ++ Wake-up Type: Power Switch ++ SKU Number: Not Specified ++ Family: Red Hat Enterprise Linux ++ ++Handle 0x0300, DMI type 3, 21 bytes ++Chassis Information ++ Manufacturer: Red Hat ++ Type: Other ++ Lock: Not Present ++ Version: RHEL 7.2.0 PC (i440FX + PIIX, 1996) ++ Serial Number: Not Specified ++ Asset Tag: Not Specified ++ Boot-up State: Safe ++ Power Supply State: Safe ++ Thermal State: Safe ++ Security Status: Unknown ++ OEM Information: 0x00000000 ++ Height: Unspecified ++ Number Of Power Cords: Unspecified ++ Contained Elements: 0 ++ ++Handle 0x0400, DMI type 4, 42 bytes ++Processor Information ++ Socket Designation: CPU 0 ++ Type: Central Processor ++ Family: Other ++ Manufacturer: Red Hat ++ ID: F3 06 00 00 FF FB 8B 07 ++ Version: RHEL 7.2.0 PC (i440FX + PIIX, 1996) ++ Voltage: Unknown ++ External Clock: Unknown ++ Max Speed: 2000 MHz ++ Current Speed: 2000 MHz ++ Status: Populated, Enabled ++ Upgrade: Other ++ L1 Cache Handle: Not Provided ++ L2 Cache Handle: Not Provided ++ L3 Cache Handle: Not Provided ++ Serial Number: Not Specified ++ Asset Tag: Not Specified ++ Part Number: Not Specified ++ Core Count: 1 ++ Core Enabled: 1 ++ Thread Count: 1 ++ Characteristics: None ++ ++Handle 0x1000, DMI type 16, 23 bytes ++Physical Memory Array ++ Location: Other ++ Use: System Memory ++ Error Correction Type: Multi-bit ECC ++ Maximum Capacity: 1 GB ++ Error Information Handle: Not Provided ++ Number Of Devices: 1 ++ ++Handle 0x1100, DMI type 17, 40 bytes ++Memory Device ++ Array Handle: 0x1000 ++ Error Information Handle: Not Provided ++ Total Width: Unknown ++ Data Width: Unknown ++ Size: 1024 MB ++ Form Factor: DIMM ++ Set: None ++ Locator: DIMM 0 ++ Bank Locator: Not Specified ++ Type: RAM ++ Type Detail: Other ++ Speed: Unknown ++ Manufacturer: Red Hat ++ Serial Number: Not Specified ++ Asset Tag: Not Specified ++ Part Number: Not Specified ++ Rank: Unknown ++ Configured Clock Speed: Unknown ++ Minimum Voltage: Unknown ++ Maximum Voltage: Unknown ++ Configured Voltage: Unknown ++ ++Handle 0x1300, DMI type 19, 31 bytes ++Memory Array Mapped Address ++ Starting Address: 0x00000000000 ++ Ending Address: 0x0003FFFFFFF ++ Range Size: 1 GB ++ Physical Array Handle: 0x1000 ++ Partition Width: 1 ++ ++Handle 0x2000, DMI type 32, 11 bytes ++System Boot Information ++ Status: No errors detected ++ ++Handle 0x7F00, DMI type 127, 4 bytes ++End Of Table ++ ++EOF +diff --git a/tests/rhev/sbin/uname b/tests/rhev/sbin/uname +new file mode 100755 +index 0000000..ab0ec89 +--- /dev/null ++++ b/tests/rhev/sbin/uname +@@ -0,0 +1,2 @@ ++#!/bin/sh - ++echo x86_64 +diff --git a/tests/rhev/sbin/virt-what-cpuid-helper b/tests/rhev/sbin/virt-what-cpuid-helper +new file mode 100755 +index 0000000..86e1188 +--- /dev/null ++++ b/tests/rhev/sbin/virt-what-cpuid-helper +@@ -0,0 +1,2 @@ ++#!/bin/sh - ++echo 'KVMKVMKVM' +diff --git a/tests/test-rhev.sh b/tests/test-rhev.sh +new file mode 100755 +index 0000000..76be547 +--- /dev/null ++++ b/tests/test-rhev.sh +@@ -0,0 +1,35 @@ ++# Test for rhev ++# Copyright (C) 2008-2016 Red Hat Inc. ++# ++# This program is free software; you can redistribute it and/or modify ++# it under the terms of the GNU General Public License as published by ++# the Free Software Foundation; either version 2 of the License, or ++# (at your option) any later version. ++# ++# This program is distributed in the hope that it will be useful, ++# but WITHOUT ANY WARRANTY; without even the implied warranty of ++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++# GNU General Public License for more details. ++# ++# You should have received a copy of the GNU General Public License ++# along with this program; if not, write to the Free Software ++# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. ++ ++root=tests/rhev ++ ++output="$(./virt-what --test-root=$root 2>&1)" ++expected="rhev ++kvm" ++ ++if [ "$output" != "$expected" ]; then ++ echo "$0: test failed because output did not match expected" ++ echo "Expected output was:" ++ echo "----------------------------------------" ++ echo "$expected" ++ echo "----------------------------------------" ++ echo "But the actual output of the program was:" ++ echo "----------------------------------------" ++ echo "$output" ++ echo "----------------------------------------" ++ exit 1 ++fi +diff --git a/virt-what.in b/virt-what.in +index 0e048a2..761fc1b 100644 +--- a/virt-what.in ++++ b/virt-what.in +@@ -203,10 +203,13 @@ if echo "$dmi" | grep -q 'Vendor: Parallels'; then + skip_qemu_kvm=true + fi + +-# Check for oVirt. ++# Check for oVirt/RHEV. + if echo "$dmi" | grep -q 'Manufacturer: oVirt'; then + echo ovirt + fi ++if echo "$dmi" | grep -q 'Product Name: RHEV Hypervisor'; then ++ echo rhev ++fi + + # Check for Xen. + +diff --git a/virt-what.pod b/virt-what.pod +index fe9567f..c7a211b 100644 +--- a/virt-what.pod ++++ b/virt-what.pod +@@ -133,7 +133,8 @@ Status: contributed by Evgeniy Sokolov + + =item B + +-The guest is running on an oVirt or RHEV node. ++The guest is running on an oVirt node. ++(See also C below). + + Status: contributed by RWMJ, not confirmed + +@@ -160,6 +161,12 @@ this. + + Status: confirmed by RWMJ. + ++=item B ++ ++The guest is running on a Red Hat Enterprise Virtualization (RHEV) node. ++ ++Status: confirmed by RWMJ ++ + =item B + + This is a User-Mode Linux (UML) guest. +-- +2.10.2 + diff --git a/SPECS/virt-what.spec b/SPECS/virt-what.spec index 2c03384..b69acef 100644 --- a/SPECS/virt-what.spec +++ b/SPECS/virt-what.spec @@ -1,14 +1,14 @@ Name: virt-what Version: 1.13 -Release: 8%{?dist} +Release: 10%{?dist} Summary: Detect if we are running in a virtual machine License: GPLv2+ URL: http://people.redhat.com/~rjones/virt-what/ Source0: http://people.redhat.com/~rjones/virt-what/files/%{name}-%{version}.tar.gz -# These patches are kept in the upstream git repo, in the rhel-7.3 branch. -# http://git.annexia.org/?p=virt-what.git;a=shortlog;h=refs/heads/rhel-7.3 +# These patches are kept in the upstream git repo, in the rhel-7.4 branch. +# http://git.annexia.org/?p=virt-what.git;a=shortlog;h=refs/heads/rhel-7.4 Patch0001: 0001-Differentiate-between-vserver-host-and-guest.patch Patch0002: 0002-Detect-new-Xen-VMs-RHBZ-973663.patch Patch0003: 0003-xen-Don-t-emit-warning-message-if-proc-xen-capabilit.patch @@ -35,6 +35,7 @@ Patch0023: 0023-qemu-kvm-try-dmidecode-on-all-targets.patch Patch0024: 0024-qemu-kvm-dmidecode-look-for-KVM.patch Patch0025: 0025-Add-support-for-detecting-ppc64-LPAR-as-virt-guests.patch Patch0026: 0026-Update-the-previous-commit-to-use-system-virt-standa.patch +Patch0027: 0027-Add-detection-of-Red-Hat-Enterprise-Virtualization-h.patch # This is provided by the build root, but we make it explicit # anyway in case this was dropped from the build root in future. @@ -43,6 +44,9 @@ BuildRequires: /usr/bin/pod2man # Required at build time in order to do 'make check' (for getopt). BuildRequires: util-linux +# Runs the 'which' program to find the helper. +Requires: which + # git is used for patch management. Since some patches touch autoconf # files, we must also install autotools. BuildRequires: git @@ -121,6 +125,14 @@ make check %changelog +* Tue Mar 28 2017 Richard W.M. Jones - 1.13-10 +- Require 'which' program + resolves: rhbz#1433005 + +* Thu Feb 16 2017 Richard W.M. Jones - 1.13-9 +- Detect RHEV/oVirt (second fix) + resolves: rhbz#1249438 + * Wed Jul 27 2016 Richard W.M. Jones - 1.13-8 - Depend on dmidecode on aarch64 resolves: rhbz#1360699