From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:40291) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QRIAr-0007qu-7A for qemu-devel@nongnu.org; Tue, 31 May 2011 02:11:30 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QRIAp-0000Ua-UA for qemu-devel@nongnu.org; Tue, 31 May 2011 02:11:29 -0400 Received: from fmmailgate03.web.de ([217.72.192.234]:47150) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QRIAp-0000UT-B6 for qemu-devel@nongnu.org; Tue, 31 May 2011 02:11:27 -0400 Message-ID: <4DE48689.7070606@web.de> Date: Tue, 31 May 2011 08:11:21 +0200 From: Jan Kiszka MIME-Version: 1.0 References: <4DE120BE.1010602@web.de> <4DE37551.6060502@siemens.com> In-Reply-To: Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig26A9E19C1735CA58FCC33788" Sender: jan.kiszka@web.de Subject: Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: BrillyWu , Blue Swirl Cc: kvm@vger.kernel.org, KaryJin@viatech.com.cn, mst@redhat.com, mtosatti@redhat.com, BrillyWu@viatech.com.cn, qemu-devel@nongnu.org, avi@redhat.com This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig26A9E19C1735CA58FCC33788 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 2011-05-31 03:25, BrillyWu wrote: > Hi, Jan >=20 >> patch which has >>> been checked. It can be compiled without any error and work >> normally. >>> The patch v3 is here now. >> >> The above text can't be used as a commit log, so this needs to be >> fixed. >> Moreover, your patch still contains at least on style issues >> scripts/checkpatch.pl should have caught. Are you sure you ran it? >> >=20 > I am sure I have checked it with the scripts/checkpatch.pl, and it > shows no error or warning. Maybe I should check whether my windows > editor and mail client can work well before sending it to you. I 'm > sorry. Sorry, you are right. Your patch revealed a bug in the checkpatch script.= Blue, this does not trigger the missing braces warning: @@ -1035,8 +1052,17 @@ void cpu_x86_cpuid(CPUX86State *env, uin { /* test if maximum index reached */ if (index & 0x80000000) { - if (index > env->cpuid_xlevel) - index =3D env->cpuid_level; + if (index > env->cpuid_xlevel) { + if (env->cpuid_xlevel2 > 0) { + /* Handle the Centaur's CPUID instruction. */ + if (index > env->cpuid_xlevel2) { + index =3D env->cpuid_xlevel2; + } else if (index < 0xC0000000) { + index =3D env->cpuid_xlevel; + } + } else + index =3D env->cpuid_xlevel; + } } else { if (index > env->cpuid_level) index =3D env->cpuid_level; > OK, I will use the previous commit log, and send it to you in the new t= hread. Thanks. I think it would be fair to fix up the braces on commit now. Jan --------------enig26A9E19C1735CA58FCC33788 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.15 (GNU/Linux) Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org/ iEUEARECAAYFAk3kho0ACgkQitSsb3rl5xRPuwCeJO96gLgohte0rcECjoiDMeQ7 4LYAl1C1B5ge9ASGi5LqLCR3ZQH5eME= =TKMx -----END PGP SIGNATURE----- --------------enig26A9E19C1735CA58FCC33788--