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: <CALCETrU79kQ35qniSVxemqVpUgtQcb3rPYcmsczbbximaY3Osg@mail.gmail.com>
Date:   Mon, 11 Dec 2017 12:06:30 -0800
From:   Andy Lutomirski <luto@...nel.org>
To:     Dave Hansen <dave.hansen@...el.com>
Cc:     Andy Lutomirski <luto@...nel.org>, X86 ML <x86@...nel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        Borislav Petkov <bp@...en8.de>,
        Brian Gerst <brgerst@...il.com>,
        David Laight <David.Laight@...lab.com>,
        Kees Cook <keescook@...omium.org>,
        Peter Zijlstra <peterz@...radead.org>,
        "Kirill A. Shutemov" <kirill.shutemov@...ux.intel.com>
Subject: Re: [PATCH PTI v2 6/6] x86/pti: Put the LDT in its own PGD if PTI is on

On Mon, Dec 11, 2017 at 11:47 AM, Dave Hansen <dave.hansen@...el.com> wrote:
> On 12/11/2017 11:39 AM, Andy Lutomirski wrote:
>>> I thought there would be a "fast path" where we just use the normal
>>> clear_LDT() LDT from the cpu_entry_area and don't have to do any of
>>> this, but I'm missing where that happens.  Do we need a check in
>>> (un)map_ldt_struct() for !mm->context.ldt?
>> I'm confused.
>>
>> if (unlikely(ldt)) {
>>   do something slowish;
>> } else {
>>   clear_LD();
>> }
>
> I was looking at the map/unmap paths.  It looks to me like the cases
> where there is map/unmap overhead, we *are* doing checking against
> mm->context.ldt.  It just wasn't visible from the patch context.
>
> In any case, it would be really nice to call that out if you revise
> these in the patch description: none of these LDT acrobatics are used in
> the common case.  Virtually every process uses the !ldt paths which
> don't do any of this.

Will do.

I'm currently fighting with the 5 level case.  I need to reorganize
the memory map a bit, but it's blowing up, and I'm not sure why yet.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ