[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <e29cbd54-95f2-52ed-508e-12c1c2520bfb@linux.intel.com>
Date: Wed, 3 Jan 2018 14:27:17 -0800
From: Dave Hansen <dave.hansen@...ux.intel.com>
To: Andy Lutomirski <luto@...nel.org>,
Thomas Gleixner <tglx@...utronix.de>
Cc: Lars Wendler <wendler.lars@....de>,
LKML <linux-kernel@...r.kernel.org>, X86 ML <x86@...nel.org>,
Borislav Betkov <bp@...en8.de>,
Peter Zijlstra <peterz@...radead.org>,
Greg KH <gregkh@...uxfoundation.org>,
Laura Abbott <labbott@...hat.com>,
Boris Ostrovsky <boris.ostrovsky@...cle.com>,
Juergen Gross <jgross@...e.com>
Subject: Re: CONFIG_PAGE_TABLE_ISOLATION=y on x86_64 causes gcc to segfault
when building x86_32 binaries
On 01/03/2018 02:14 PM, Andy Lutomirski wrote:
> + /* Use %rsp as scratch reg. User ESP is stashed in r8 */
> + SWITCH_TO_KERNEL_CR3 scratch_reg=%rsp
> +
> + /* Switch to the kernel stack */
> movq PER_CPU_VAR(cpu_current_top_of_stack), %rsp
The stack is unreadable at this point without the CR3 switch.
> What's the issue that this is fixing?
Users doing 32-bit SYSCALLs on the CPUs that support them double fault
since they end up with an %rsp that they can't access.
Powered by blists - more mailing lists