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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20120822084702.GA21764@gmail.com>
Date:	Wed, 22 Aug 2012 10:47:02 +0200
From:	Ingo Molnar <mingo@...nel.org>
To:	Ido Yariv <ido@...ery.com>
Cc:	linux-kernel@...r.kernel.org, Thomas Gleixner <tglx@...utronix.de>,
	Ingo Molnar <mingo@...hat.com>,
	"H. Peter Anvin" <hpa@...or.com>, Shai Fultheim <shai@...lemp.com>
Subject: Re: [PATCH v2 2/2] x86/pat: Avoid contention on cpa_lock if possible


* Ido Yariv <ido@...ery.com> wrote:

> vSMP Foundation does not require to serialize CPA by guaranteeing that
> the most recent TLB entry will always be used.
> 
> To avoid needless contention on cpa_lock, do not lock/unlock it if it
> isn't necessary.
> 
> Based on work by Shai Fultheim <shai@...lemp.com>.
> 
> Signed-off-by: Ido Yariv <ido@...ery.com>
> Acked-by: Shai Fultheim <shai@...lemp.com>
> ---
> Changes from v1:
> - Use a synthetic CPUID bit and a use static_cpu_has() as suggested by
>   H. Peter Avnin
> 
>  arch/x86/include/asm/cpufeature.h |    1 +
>  arch/x86/kernel/vsmp_64.c         |   10 ++++++++++
>  arch/x86/mm/pageattr.c            |   30 +++++++++++++++++++++---------
>  3 files changed, 32 insertions(+), 9 deletions(-)
> 
> diff --git a/arch/x86/include/asm/cpufeature.h b/arch/x86/include/asm/cpufeature.h
> index 6b7ee5f..92303a0 100644
> --- a/arch/x86/include/asm/cpufeature.h
> +++ b/arch/x86/include/asm/cpufeature.h
> @@ -97,6 +97,7 @@
>  #define X86_FEATURE_EXTD_APICID	(3*32+26) /* has extended APICID (8 bits) */
>  #define X86_FEATURE_AMD_DCM     (3*32+27) /* multi-node processor */
>  #define X86_FEATURE_APERFMPERF	(3*32+28) /* APERFMPERF */
> +#define X86_FEATURE_NO_CPA_LOCK	(3*32+29) /* Serializing cpa is not required */

Patch looks mostly good, but could we please use some more 
hardware-ish name, instead of referring to a kernel lock?

I.e. how would you name it if this was a real hardware feature? 
Certainly not 'No CPA Lock'.

Thanks,

	Ingo
--
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