From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60392) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V6OoL-0003U2-IM for qemu-devel@nongnu.org; Mon, 05 Aug 2013 13:43:19 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V6OoF-00072d-Il for qemu-devel@nongnu.org; Mon, 05 Aug 2013 13:43:13 -0400 Received: from mx1.redhat.com ([209.132.183.28]:20808) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V6OoF-00072S-BE for qemu-devel@nongnu.org; Mon, 05 Aug 2013 13:43:07 -0400 Date: Mon, 5 Aug 2013 20:43:02 +0300 From: Gleb Natapov Message-ID: <20130805174302.GD15901@redhat.com> References: <20130805171730.1100.98667.malonedeb@wampee.canonical.com> <20130805171730.1100.98667.malonedeb@wampee.canonical.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20130805171730.1100.98667.malonedeb@wampee.canonical.com> Subject: Re: [Qemu-devel] [Bug 1208540] [NEW] RDMSR of register 0x345 (IA32_PERF_CAPABILITIES) fails in guest List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Bug 1208540 <1208540@bugs.launchpad.net> Cc: qemu-devel@nongnu.org On Mon, Aug 05, 2013 at 05:17:30PM -0000, Jari Ruusu wrote: > Public bug reported: > > I have a problem with qemu when I attempt to configure qemu in a way that > AES-NI op-codes are enabled in quest. To do that, I have to configure qemu > to emulate a recent CPU. But that causes a problem, because with recent > CPUs, guest linux kernel code assumes that RDMSR of register 0x345 works. > Qemu does not handle that correctly. Qemu does not crash. Guests running > newer linux kernels always crash on boot with 'general protection fault' on > RDMSR op-code that attempts to read IA32_PERF_CAPABILITIES. That "crashing" > linux code works OK on bare metal. > This is not QEMU/KVM bug, this is kernel bug since it should not touch this MSR if cpuid does not have PDCM bit. Compile your guest kernel with paravirt support (which is a good idea for many reasons) and the crash will disappear. -- Gleb.