lkml.org 
[lkml]   [2017]   [Nov]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 02/23] x86, kaiser: do not set _PAGE_USER for init_mm page tables
On Tue, 31 Oct 2017, Dave Hansen wrote:

>
> init_mm is for kernel-exclusive use. If someone is allocating page
> tables in it, do not set _PAGE_USER on them. This ensures that
> we do *not* set NX on these page tables in the KAISER code.

This changelog is confusing at best.

Why is this a kaiser issue? Nothing should ever create _PAGE_USER entries
in init_mm, right?

So this is a general improvement and creating a _PAGE_USER entry in init_mm
should be considered a bug in the first place.

> +/*
> + * _KERNPG_TABLE has _PAGE_USER clear which tells the KAISER code
> + * that this mapping is for kernel use only. That makes sure that
> + * we leave the mapping usable by the kernel and do not try to
> + * sabotage it by doing stuff like setting _PAGE_NX on it.

So this comment should not mention KAISER at all. As I explained above
there are no user mappings in init_mm and this should be expressed here.

The fact that KAISER can make use of this information is a different story.

Other than that:

Reviewed-by: Thomas Gleixner <tglx@linutronix.de>

Thanks,

tglx

\
 
 \ /
  Last update: 2017-11-01 22:12    [W:0.332 / U:35.432 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site