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:   Sat, 30 Dec 2017 11:03:30 -0800
From:   Dave Hansen <dave.hansen@...ux.intel.com>
To:     Linus Torvalds <torvalds@...ux-foundation.org>,
        Thomas Gleixner <tglx@...utronix.de>
Cc:     Dominik Brodowski <linux@...inikbrodowski.net>,
        Andy Lutomirski <luto@...nel.org>,
        LKML <linux-kernel@...r.kernel.org>,
        the arch/x86 maintainers <x86@...nel.org>
Subject: Re: x86/pti: smp_processor_id() called while preemptible in
 resume-from-sleep

On 12/30/2017 10:40 AM, Linus Torvalds wrote:
> The __native_flush_tlb() function looks _very_ broken.
...
> So I'd suggest moving the preempt_disable() up to the top of that
> function, regardless of whether we could then remove that seemingly
> stale TLB flush in that crazy
> smpboot_setup/restore_warm_reset_vector() dance...

If someone is calling __native_flush_tlb(), shouldn't they already be in
a state where they can't be preempted?  It's fundamentally a one-cpu
thing, both the actual CPU TLB flush _and_ the per-cpu variables.

It seems like we might want to _remove_ the explicit
preempt_dis/enable() from here:

        preempt_disable();
        native_write_cr3(__native_read_cr3());
        preempt_enable();

and add some warnings to ensure it's disabled when we enter
__native_flush_tlb().

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ