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: <75a3b68c-ba51-b479-1d01-62a1c05316cc@molgen.mpg.de>
Date:   Mon, 18 Sep 2017 10:17:43 +0200
From:   Paul Menzel <pmenzel@...gen.mpg.de>
To:     mingo@...nel.org, bpetkov@...e.de, peterz@...radead.org,
        bp@...en8.de, tglx@...utronix.de, pavel@....cz, hpa@...or.com,
        luto@...nel.org, torvalds@...ux-foundation.org,
        linux-kernel@...r.kernel.org, linux-tip-commits@...r.kernel.org
Subject: Re: [tip:x86/urgent] x86/mm/32: Load a sane CR3 before cpu_init() on
 secondary CPUs

Dear Andy,


On 09/17/17 20:19, tip-bot for Andy Lutomirski wrote:
> Commit-ID:  4ba55e65f471d011d3ba2ac2022180ea0877d68e
> Gitweb:     http://git.kernel.org/tip/4ba55e65f471d011d3ba2ac2022180ea0877d68e
> Author:     Andy Lutomirski <luto@...nel.org>
> AuthorDate: Sun, 17 Sep 2017 09:03:51 -0700
> Committer:  Ingo Molnar <mingo@...nel.org>
> CommitDate: Sun, 17 Sep 2017 18:59:09 +0200
> 
> x86/mm/32: Load a sane CR3 before cpu_init() on secondary CPUs
> 
> For unknown historical reasons (i.e. Borislav doesn't recall),
> 32-bit kernels invoke cpu_init() on secondary CPUs with
> initial_page_table loaded into CR3.  Then they set
> current->active_mm to &init_mm and call enter_lazy_tlb() before
> fixing CR3.

If this should be changed, I’d be happy to help.

> This means that the x86 TLB code gets invoked while CR3
> is inconsistent, and, with the improved PCID sanity checks I added,
> we warn.
> 
> Fix it by loading swapper_pg_dir (i.e. init_mm.pgd) earlier.
> 
> Reported-by: Paul Menzel <pmenzel@...gen.mpg.de>
> Reported-by: Pavel Machek <pavel@....cz>
> Signed-off-by: Andy Lutomirski <luto@...nel.org>
> Cc: Borislav Petkov <bp@...en8.de>
> Cc: Borislav Petkov <bpetkov@...e.de>
> Cc: Linus Torvalds <torvalds@...ux-foundation.org>
> Cc: Peter Zijlstra <peterz@...radead.org>
> Cc: Thomas Gleixner <tglx@...utronix.de>
> Fixes: 72c0098d92ce ("x86/mm: Reinitialize TLB state on hotplug and resume")
> Link: http://lkml.kernel.org/r/30cdfea504682ba3b9012e77717800a91c22097f.1505663533.git.luto@kernel.org

This should use the HTTPS protocol.

> Signed-off-by: Ingo Molnar <mingo@...nel.org>
> ---
>   arch/x86/kernel/smpboot.c | 13 +++++++------
>   1 file changed, 7 insertions(+), 6 deletions(-)

[…]

Thank you for the fix.

Tested-by: Paul Menzel <pmenzel@...gen.mpg.de> (Lenovo X60t)


Kind regards,

Paul

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ