lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4FA9CB38.3080606@intel.com>
Date:	Wed, 09 May 2012 09:41:12 +0800
From:	Alex Shi <alex.shi@...el.com>
To:	"H. Peter Anvin" <hpa@...or.com>
CC:	mgorman@...e.de, npiggin@...il.com, tglx@...utronix.de,
	mingo@...hat.com, arnd@...db.de, rostedt@...dmis.org,
	fweisbec@...il.com, jeremy@...p.org, gregkh@...uxfoundation.org,
	glommer@...hat.com, riel@...hat.com, luto@....edu, avi@...hat.com,
	len.brown@...el.com, dhowells@...hat.com, fenghua.yu@...el.com,
	borislav.petkov@....com, yinghai@...nel.org, ak@...ux.intel.com,
	cpw@....com, steiner@....com, akpm@...ux-foundation.org,
	penberg@...nel.org, hughd@...gle.com, rientjes@...gle.com,
	kosaki.motohiro@...fujitsu.com, n-horiguchi@...jp.nec.com,
	paul.gortmaker@...driver.com, trenn@...e.de, tj@...nel.org,
	oleg@...hat.com, axboe@...nel.dk, a.p.zijlstra@...llo.nl,
	kamezawa.hiroyu@...fujitsu.com, viro@...iv.linux.org.uk,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3 4/7] x86/tlb: add tlb flush all factor for specific
 CPUs

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@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ