From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:60106) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TB83r-0006H3-BB for qemu-devel@nongnu.org; Mon, 10 Sep 2012 13:46:19 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TB83m-0003pj-LD for qemu-devel@nongnu.org; Mon, 10 Sep 2012 13:46:15 -0400 Received: from v220110690675601.yourvserver.net ([78.47.199.172]:39709) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TB83m-0003oa-BR for qemu-devel@nongnu.org; Mon, 10 Sep 2012 13:46:10 -0400 Message-ID: <504E275F.4090006@weilnetz.de> Date: Mon, 10 Sep 2012 19:46:07 +0200 From: Stefan Weil MIME-Version: 1.0 References: <504AC909.8090502@weilnetz.de> <504E140F.8060102@weilnetz.de> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] QEMU (no kvm) Win7 (64bit) boot error List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Clemens Kolbitsch Cc: Andre Przywara , qemu-devel@nongnu.org, Aurelien Jarno Am 10.09.2012 19:20, schrieb Clemens Kolbitsch: > On Mon, Sep 10, 2012 at 9:23 AM, Stefan Weil wrote: > > > Hi Clemens, > > indeed, it looks like CPUID_DE fixes that BSOD with "STOP 0x0000005D ..= .". > In my test scenario Windows now reboots instead of showing the BSOD. > > This commit added the TCG feature bit trimming which broke Windows: > > commit 551a2dec8fa55006a68393b9d6fb63577d2b3f1c > Autor: Andre Przywara Do M=E4r 11 14:39:03= 2010 > Eintragender: Aurelien Jarno Sa M=E4r 13 16:= 50:54 > 2010 > > x86/cpuid: add TCG feature bit trimming > > In KVM we trim the user provided CPUID bits to match the host CPU's > one. Introduce a similar feature to QEMU/TCG. Create a mask of TCG's > capabilities and apply it to the user bits. > This allows to let the CPU models reflect their native archetypes. > > Signed-off-by: Andre Przywara > Signed-off-by: Aurelien Jarno > > > Andre, why don't we set the requested feature bits - no matter what TCG > provides? > Stefan, > > could you tell me what QEMU ( ;-) ) HW configuration you use for your > testing? I'm able to boot, but it still is very unstable - after a few > seconds of running, I still run into BSODs. I think it's independent > of the bug I was working on, but I'd like to test some more. I run qemu-system-x86_64 (latest from git) withthe default CPU on a 64 bit Windows 7 host. QEMU uses that host's installation: qemu-system-x86_64 -m 1024 -snapshot -hda //PhysicalDrive/0 > > BTW, I'm actually quite confident that the missing CPU-ID bit caused > the 0x5D booting BSOD, since I took two kernel boot traces (one of > QEMU stable crashing and a working VM) and the location the traces > branched off from each other was where the CPU-ID bits were checked > (and this one feature bit was the only thing that was not set properly > for the check to succeed). > > -Clemens CPUID_DE is part of the PENTIUM_FEATURES macro, therefore I think it's a very old feature which was already supported by the Pentium CPU family. No wonder Windows complains when it is missing. This and maybe some more bits (there is a comment 'needed for Win64' for CPUID_MTRR, CPUID_MCA, CPUID_CLFLUSH which were also removed) should be set in TCG mode (as they are set with KVM). There remain two questions: * Do we need some TCG implementation for those bits? * Should the patch which adds CPUID_DEagain be committed before the other question was answered? Any patch in this area should also be sent to qemu-stable: this BSOD with Windows guests running on QEMU occurs rather often (just run a search on a web search engine to get many hits). Regards, Stefan