<div dir="ltr">Hi Cristian,<div><br></div><div>Please do post comments on patch on the mailing list.</div><div><br></div><div style>Regarding the message itself, quoted below, I am addressing your specific concerns.</div><div style>
- There is no performance impact between "qemu64" and "host" CPU options. The only thing changing is the level of private instructions that the kernel will attempt - which should be clearly restricted to "qemu64" and not "host" since we build Yocto for the "qemu" machine. </div>
<div style>- I agree that there is an underlying problem in the kernel, but that is not our primary concern, see no 1. It might be our concern if we'd build for a specific BSP which showed the problem, but as it stands, it's KVM folk's concern. Funny enough, they know about the problem (I tracked on their mailing list), but they don't have a fix since it runs as it's designed right now - that is, the faulty behavior is a result of how it should work with the current design.</div>
<div style><br></div><div style>I still recommend merging this patch since it fixes the problem with the right fix.</div><div style><br></div><div style>Cheers,</div><div style>Alex </div><div style><br></div><div style>Original message:</div>
<div style><pre class="" style="white-space:pre-wrap;width:50em;color:rgb(0,0,0)">Hi Alex,
I might be wrong, and I need more time to investigate, but I don't agree with the fix you proposed for this issue.
What you propose is just a step back from how qemu should optimally work, meaning exporting "-cpu host".
That's one thing.
Another thing is the described issue seems to be specific to some kernels on the host.
For example, I checked with LaurP and AlexG and thes issue is:
- reproducible on Ubuntu 12.10 with kernel 3.5.0.27 and Fedora Core 18 with kernel 3.8.5.
- not reproducible with Ubuntu 12.04 with kernel 3.2.x (need to check the exact details with LaurP).
This issue needs more investigation.
Regards,
Cristian</pre></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Apr 15, 2013 at 9:58 AM, Iorga, Cristian <span dir="ltr"><<a href="mailto:cristian.iorga@intel.com" target="_blank">cristian.iorga@intel.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Alex,<br>
<br>
See my comments regarding this patch at:<br>
<a href="https://bugzilla.yoctoproject.org/show_bug.cgi?id=3908" target="_blank">https://bugzilla.yoctoproject.org/show_bug.cgi?id=3908</a><br>
<br>
Regards,<br>
Cristian<br>
<div><div class="h5"><br>
-----Original Message-----<br>
From: <a href="mailto:openembedded-core-bounces@lists.openembedded.org">openembedded-core-bounces@lists.openembedded.org</a> [mailto:<a href="mailto:openembedded-core-bounces@lists.openembedded.org">openembedded-core-bounces@lists.openembedded.org</a>] On Behalf Of Alex DAMIAN<br>
Sent: Tuesday, April 09, 2013 5:47 PM<br>
To: <a href="mailto:richard.purdie@linuxfoundation.org">richard.purdie@linuxfoundation.org</a>; <a href="mailto:tom.zanussi@linux.intel.com">tom.zanussi@linux.intel.com</a>; Burton, Ross; <a href="mailto:paul.eggleton@linux.intel.com">paul.eggleton@linux.intel.com</a>; <a href="mailto:openembedded-core@lists.openembedded.org">openembedded-core@lists.openembedded.org</a><br>
Cc: Damian, Alexandru<br>
Subject: [OE-core] [PATCH] qemu: use default qemu CPU definition<br>
<br>
From: Alexandru DAMIAN <<a href="mailto:alexandru.damian@intel.com">alexandru.damian@intel.com</a>><br>
<br>
This fixes guest crashes when trying to use restricted instructions based on CPU description. Using default qemu CPU descriptions restrict faults on using restricted model-specific registers.<br>
<br>
[YOCTO #3908]<br>
<br>
Signed-off-by: Alexandru DAMIAN <<a href="mailto:alexandru.damian@intel.com">alexandru.damian@intel.com</a>><br>
---<br>
scripts/runqemu | 2 +-<br>
scripts/runqemu-internal | 6 ++++--<br>
2 files changed, 5 insertions(+), 3 deletions(-)<br>
<br>
diff --git a/scripts/runqemu b/scripts/runqemu index 8ed1226..43d7600 100755<br>
--- a/scripts/runqemu<br>
+++ b/scripts/runqemu<br>
@@ -261,7 +261,7 @@ if [ "x$KVM_ENABLED" = "xyes" ]; then<br>
exit 1;<br>
fi<br>
if [ -w /dev/kvm -a -r /dev/kvm ]; then<br>
- SCRIPT_QEMU_OPT="$SCRIPT_QEMU_OPT -enable-kvm -cpu host"<br>
+ SCRIPT_QEMU_OPT="$SCRIPT_QEMU_OPT -enable-kvm "<br>
KVM_ACTIVE="yes"<br>
else<br>
echo "You have no rights on /dev/kvm."<br>
diff --git a/scripts/runqemu-internal b/scripts/runqemu-internal index e8191d1..a7813e5 100755<br>
--- a/scripts/runqemu-internal<br>
+++ b/scripts/runqemu-internal<br>
@@ -323,10 +323,11 @@ fi<br>
<br>
if [ "$MACHINE" = "qemux86" ]; then<br>
QEMU=qemu-system-i386<br>
+ QEMU_CPU_OPTIONS="-cpu qemu32"<br>
QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS -vga vmware"<br>
if [ "$FSTYPE" = "ext2" -o "$FSTYPE" = "ext3" -o "$FSTYPE" = "btrfs" ]; then<br>
KERNCMDLINE="vga=0 uvesafb.mode_option=640x480-32 root=$DROOT rw mem=$QEMU_MEMORY $KERNEL_NETWORK_CMD"<br>
- QEMUOPTIONS="$QEMU_NETWORK_CMD $ROOTFS_OPTIONS $QEMU_UI_OPTIONS"<br>
+ QEMUOPTIONS="$QEMU_NETWORK_CMD $ROOTFS_OPTIONS $QEMU_CPU_OPTIONS $QEMU_UI_OPTIONS"<br>
fi<br>
if [ "$FSTYPE" = "nfs" ]; then<br>
if [ "$NFS_SERVER" = "192.168.7.1" -a ! -d "$NFS_DIR" ]; then @@ -347,10 +348,11 @@ fi<br>
<br>
if [ "$MACHINE" = "qemux86-64" ]; then<br>
QEMU=qemu-system-x86_64<br>
+ QEMU_CPU_OPTIONS="-cpu qemu64"<br>
QEMU_UI_OPTIONS="$QEMU_UI_OPTIONS -vga vmware"<br>
if [ "$FSTYPE" = "ext3" -o "$FSTYPE" = "btrfs" ]; then<br>
KERNCMDLINE="vga=0 root=$DROOT rw mem=$QEMU_MEMORY $KERNEL_NETWORK_CMD"<br>
- QEMUOPTIONS="$QEMU_NETWORK_CMD $ROOTFS_OPTIONS $QEMU_UI_OPTIONS"<br>
+ QEMUOPTIONS="$QEMU_NETWORK_CMD $ROOTFS_OPTIONS $QEMU_CPU_OPTIONS $QEMU_UI_OPTIONS"<br>
fi<br>
if [ "$FSTYPE" = "nfs" ]; then<br>
if [ "x$ROOTFS" = "x" ]; then<br>
--<br>
1.7.10.4<br>
<br>
<br>
</div></div>_______________________________________________<br>
Openembedded-core mailing list<br>
<a href="mailto:Openembedded-core@lists.openembedded.org">Openembedded-core@lists.openembedded.org</a><br>
<a href="http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core" target="_blank">http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core</a><br>
</blockquote></div><br></div>