[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU
From: |
Jan Kiszka |
Subject: |
Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU |
Date: |
Tue, 31 May 2011 09:50:15 +0200 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686 (x86_64); de; rv:1.8.1.12) Gecko/20080226 SUSE/2.0.0.12-1.1 Thunderbird/2.0.0.12 Mnenhy/0.7.5.666 |
On 2011-05-31 09:39, BrillyWu wrote:
> Hi, Jan
>
>>> 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:
>
> Do you mean the bug is that it can not trigger missing braces warining?
The script fails to detect missing braces as marked below.
> It seems that there is no missing braces in my patch, but some
> unnecessary braces.
There are no unnecessary braces according to QEMU coding style.
>
>>
>> @@ -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 = 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 = env->cpuid_xlevel2;
>> + } else if (index < 0xC0000000) {
>> + index = env->cpuid_xlevel;
>> + }
>> + } else
>> + index = env->cpuid_xlevel;
This should be:
} else {
index = ...
}
>> + }
>> } else {
>> if (index > env->cpuid_level)
>> index = env->cpuid_level;
>>
>>
>>> OK, I will use the previous commit log, and send it to you
>> in the new thread.
>>
>> Thanks. I think it would be fair to fix up the braces on commit now.
>
> It looks that there are some unnecessary braces, but if I remove them,
> the script/checkpatch.pl will report warnings. Could I ignore it?
Nope, see above.
> BTW, I have submited a patch v3 a few minutes before withou fixing up
> the braces, and I have tested it with my mail client this time, so it
> could be OK now.
Yes, your mail client works fine as far as I can see.
Jan
signature.asc
Description: OpenPGP digital signature
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU, (continued)
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU, Jan Kiszka, 2011/05/28
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU, Jan Kiszka, 2011/05/28
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU, BrillyWu, 2011/05/30
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU, BrillyWu, 2011/05/30
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU, Jan Kiszka, 2011/05/30
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU, BrillyWu, 2011/05/30
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU, Jan Kiszka, 2011/05/30
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU, BrillyWu, 2011/05/30
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU, Jan Kiszka, 2011/05/31
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU, BrillyWu, 2011/05/31
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU,
Jan Kiszka <=
- Re: [Qemu-devel] [PATCH uq/master V2] kvm: Add CPUID support for VIA CPU, BrillyWu, 2011/05/31