Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
Version-Release number of selected component (if applicable):
# uname -r
2.6.32-128.el6.x86_64
# rpm -q qemu-kvm
qemu-kvm-0.12.1.2-2.153.el6.x86_64
How reproducible:
100%
Steps to Reproduce:
1.<commandline> -cpu Penryn,+ace,enforce ( ace is the flag on Westmere cpu model)
2.<commandLine> -cpu Conroe,+smx,enforce ( smx is the flag on Westmere cpu model)
3.<commandLine> -cpu Nehalem,+ace,enforce
Actual results:
QEMU runs in both cases
Expected results:
QEMU does not run
Additional info:
#<commandLine> -cpu host,+ace,enforce
CPU feature ace not found
warning: host cpuid 0000_0001:ecx flag restricted to guest 'vmx' [0x00000020]
Unable to support requested x86 CPU definition
#<commandLine> -cpu cpu64-rhel6,+ace,enforce
CPU feature ace not found
warning: host cpuid 8000_0001:ecx lacks requested flag 'svm' [0x00000004]
warning: host cpuid 8000_0001:ecx lacks requested flag 'abm' [0x00000020]
warning: host cpuid 8000_0001:ecx lacks requested flag 'sse4a' [0x00000040]
Unable to support requested x86 CPU definition
Yes that is the default "-cpu" flag parsing of qemu, namely it doesn't
bail if unknown flags are present:
# x86_64-softmmu/qemu-system-x86_64 -smp 1 -netic -net user ../../winxp-64.img \
-m 1024 -cpu Penryn,+popcnt,+ou812,+sse4_2,check
Using CPU model "Penryn,+popcnt,+ou812,+sse4_2,check"
CPU feature ou812 not found
warning: host cpuid 0000_0001:ecx lacks requested flag 'sse4.2|sse4_2' [0x00100000]
warning: host cpuid 0000_0001:ecx lacks requested flag 'popcnt' [0x00800000]
<guest launches>
But you're right "enforce" semantics should be held (in addition to
complaining) and qemu should error exit. It's a nit and should be
cleaned up the next time we're in that section of the code.
Not only non-existing flags are not rejected properly, but also flags that exist, are supported by the host, but unsupported by the kernel. e.g.:
-cpu Opteron_G3,+ht,-svm,enforce
HT is not supported by the KVM kernel module and gets disabled, but Qemu continues to run without aborting.