Re: [PATCH v3 4/7] x86/tlb: add tlb flush all factor for specificCPUs

From: Alex Shi
Date: Tue May 08 2012 - 21:43:17 EST


On 05/08/2012 11:18 PM, H. Peter Anvin wrote:

> On 05/08/2012 07:03 AM, Alex Shi wrote:
>>
>> - if (!cpu_has_invlpg || vma->vm_flags & VM_HUGETLB) {
>> + if (!cpu_has_invlpg || vma->vm_flags & VM_HUGETLB
>> + || !tlb_flushall_factor) {
>
> OK nevermind on the division by zero, but this yet another test being
> performed.
>
> If nothing else you could fold these tests and make tlb_flushall_factor
> zero if !cpu_has_invlpg.


Yes, should be.

>
> -hpa
>


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/