From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Michael S. Tsirkin" Subject: x86info: dump kvm cpuid's Date: Sun, 29 Apr 2012 13:10:21 +0300 Message-ID: <20120429101019.GA21165@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii To: davej@redhat.com, kvm@vger.kernel.org, gleb@redhat.com Return-path: Received: from mx1.redhat.com ([209.132.183.28]:10548 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751802Ab2D2KKQ (ORCPT ); Sun, 29 Apr 2012 06:10:16 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q3TAAFp0001072 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Sun, 29 Apr 2012 06:10:16 -0400 Content-Disposition: inline Sender: kvm-owner@vger.kernel.org List-ID: The following makes 'x86info -r' dump kvm cpu ids (signature+features) when running in a vm. On the guest we see the signature and the features: eax in: 0x40000000, eax = 00000000 ebx = 4b4d564b ecx = 564b4d56 edx = 0000004d eax in: 0x40000001, eax = 0100007b ebx = 00000000 ecx = 00000000 edx = 00000000 On the host it just adds a couple of zero lines: eax in: 0x40000000, eax = 00000000 ebx = 00000000 ecx = 00000000 edx = 00000000 eax in: 0x40000001, eax = 00000000 ebx = 00000000 ecx = 00000000 edx = 00000000 Signed-off-by: Michael S. Tsirkin --- Dave - not sure whether there's a mailing list for x86info. The patch is on top of the master branch in git://git.codemonkey.org.uk/x86info.git Thanks! diff --git a/x86info.c b/x86info.c index 22c4734..dee5ed1 100644 --- a/x86info.c +++ b/x86info.c @@ -44,6 +44,7 @@ static void display_detailed_info(struct cpudata *cpu) if (cpu->maxei2 >=0xC0000000) dump_raw_cpuid(cpu->number, 0xC0000000, cpu->maxei2); + dump_raw_cpuid(cpu->number, 0x40000000, 0x40000001); } if (show_cacheinfo) {