lkml.org 
[lkml]   [2019]   [Feb]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH] x86/asm: Pin sensitive CR4 bits
On Wed, Feb 20, 2019 at 12:15 AM Dominik Brodowski
<linux@dominikbrodowski.net> wrote:
>
> On Tue, Feb 19, 2019 at 04:54:49PM -0800, Kees Cook wrote:
> > diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c
> > index cb28e98a0659..7e0ea4470f8e 100644
> > --- a/arch/x86/kernel/cpu/common.c
> > +++ b/arch/x86/kernel/cpu/common.c
> > @@ -312,10 +312,16 @@ static __init int setup_disable_smep(char *arg)
> > }
> > __setup("nosmep", setup_disable_smep);
> >
> > +volatile unsigned long cr4_pin __ro_after_init;
> > +EXPORT_SYMBOL_GPL(cr4_pin);
>
> Where is this export needed?

I use it in lkdtm (which I was going to land through the drivers tree,
but I haven't sent to Greg):

https://git.kernel.org/pub/scm/linux/kernel/git/kees/linux.git/commit/?h=kspp/x86/cr4

--
Kees Cook

\
 
 \ /
  Last update: 2019-02-20 18:02    [W:0.048 / U:0.784 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site