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]
Date:	Wed, 17 Jun 2015 13:11:41 +0200
From:	Borislav Petkov <bp@...e.de>
To:	Andy Lutomirski <luto@...nel.org>
Cc:	x86@...nel.org, Peter Zijlstra <peterz@...radead.org>,
	John Stultz <john.stultz@...aro.org>,
	linux-kernel@...r.kernel.org, Len Brown <lenb@...nel.org>,
	Huang Rui <ray.huang@....com>,
	Denys Vlasenko <dvlasenk@...hat.com>, kvm@...r.kernel.org,
	Ralf Baechle <ralf@...ux-mips.org>
Subject: Re: [PATCH v3 00/18] x86/tsc: Clean up rdtsc helpers

On Tue, Jun 16, 2015 at 05:35:48PM -0700, Andy Lutomirski wrote:
> My sincere apologies for the spam.  I send an unholy mixture of the
> real patch set and an old poorly split-up patch set, and the result
> is incomprehensible.  Here's what I meant to send.
> 
> After the some recent threads about rdtsc barriers, I remembered
> that our RDTSC wrappers are a big mess.  Let's clean it up.
> 
> Currently we have rdtscl, rdtscll, native_read_tsc,
> paravirt_read_tsc, and rdtsc_barrier.  For people who haven't
> noticed rdtsc_barrier and who haven't carefully read the docs,
> there's no indication that all of the other accessors have a giant
> ordering gotcha.  The macro forms are ugly, and the paravirt
> implementation is completely pointless.
> 
> rdtscl is particularly awful.  It reads the low bits.  There are no
> performance critical users of just the low bits anywhere in the
> kernel.
> 
> Clean it up.  After this patch set, there are exactly three
> functions.  rdtsc_unordered() is a function that does a raw RDTSC
> and returns a 64-bit number.  rdtsc_ordered() is a function that
> does a properly ordered RDTSC for general-purpose use.
> barrier_before_rdtsc() is exactly what it sounds like.
> 
> Changes from v2:
>  - Rename rdtsc_unordered to just rdtsc
>  - Get rid of rdtsc_barrier entirely instead of renaming it
>  - The KVM patch is new (see above)
>  - Added some acks

peterz reminded me that I'm lazy actually and don't reply to each patch :)

So, I like it, looks good, nice cleanup. It boots on my guest here - I
haven't done any baremetal testing though. Let's give people some more
time to look at it...

Thanks.

-- 
Regards/Gruss,
    Boris.

ECO tip #101: Trim your mails when you reply.
--
--
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