RE: [PATCH v2 3/4] x86, head_32/64.S: Enable SMEP
From: Yu, Fenghua
Date: Tue May 17 2011 - 19:10:55 EST
> -----Original Message-----
> From: Matthew Garrett [mailto:mjg@xxxxxxxxxx]
> Sent: Monday, May 16, 2011 7:10 PM
> To: Yu, Fenghua
> Cc: Ingo Molnar; Thomas Gleixner; H Peter Anvin; Mallick, Asit K; Linus
> Torvalds; Avi Kivity; Arjan van de Ven; Andrew Morton; Andi Kleen;
> Subject: Re: [PATCH v2 3/4] x86, head_32/64.S: Enable SMEP
> On Mon, May 16, 2011 at 02:34:44PM -0700, Fenghua Yu wrote:
> > From: Fenghua Yu <fenghua.yu@xxxxxxxxx>
> > Enable newly documented SMEP (Supervisor Mode Execution Protection)
> > feature in kernel.
> > SMEP prevents the CPU in kernel-mode to jump to an executable page
> that does
> > not have the kernel/system flag set in the pte. This prevents the
> > from executing user-space code accidentally or maliciously, so it for
> > prevents kernel exploits from jumping to specially prepared user-mode
> > code. The violation will cause page fault #PF and will have error
> > identical to XD violation.
> Are EFI runtime service pages currently set up appropriately?
They are not set up yet. efi init is called after this.
But at this time there is no user space code yet. So there is no SMEP violation chance until later when any user space page table is setup.
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/