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: <20160406115215.GK2906@worktop>
Date:	Wed, 6 Apr 2016 13:52:15 +0200
From:	Peter Zijlstra <peterz@...radead.org>
To:	Alexander Shishkin <alexander.shishkin@...ux.intel.com>
Cc:	Gleb Natapov <gleb@...nel.org>,
	Paolo Bonzini <pbonzini@...hat.com>, x86@...nel.org,
	kvm@...r.kernel.org, Ingo Molnar <mingo@...hat.com>,
	linux-kernel@...r.kernel.org, tglx@...utronix.de, hpa@...or.com,
	Arnaldo Carvalho de Melo <acme@...radead.org>,
	Borislav Petkov <bp@...en8.de>
Subject: Re: [PATCH] perf/x86/intel/pt: Don't die on VMXON

On Wed, Apr 06, 2016 at 02:10:49PM +0300, Alexander Shishkin wrote:
> >> +	/* may be already stopped by a PMI*/
> >> +	if (!(ctl & RTIT_CTL_TRACEEN))
> >> +		return;
> >> +
> >> +	ctl ^= RTIT_CTL_TRACEEN;
> >
> > Would that not be much less confusing when written like |= ?
> 
> This one's actually clearing TraceEn, see the if-not-set-leave in front
> of it, but that just goes to prove your point I guess. :)

Hehe, indeed. So much for pretending to be awake :-)


> How about this then:

Looks good, however:

> +	if (test_cpu_cap(&boot_cpu_data, X86_FEATURE_VMX)) {

Borislav tells me this ought to be boot_cpu_has(X86_FEATURE_VMX)

> +		/* Intel SDM, 36.5 "Tracing post-VMXON" */
> +		rdmsrl(MSR_IA32_VMX_MISC, reg);
> +		if (reg & BIT(14))
> +			pt_pmu.vmx = true;
> +	}

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ