Re: [RFC PATCH 0/5] Use an alternative to _PAGE_PROTNONE for _PAGE_NUMA v2

From: Linus Torvalds
Date: Tue Apr 08 2014 - 13:42:04 EST


On Tue, Apr 8, 2014 at 10:30 AM, Peter Zijlstra <peterz@xxxxxxxxxxxxx> wrote:
>
> Like this:
>
> https://lkml.org/lkml/2012/11/13/431
>
> That used the generic PROT_NONE infrastructure and compared, on fault,
> the page protection bits against the vma->vm_page_prot bits?
>
> So the objection to that approach was the vma-> dereference in
> pte_numa() ?

So the important thing is that as long as it works exactly like
PROT_NONE as far as hardware (and that includes paravirtualized setups
too!) then I guess we should be ok.

But that "pte_numa()" does make me go "Hmm.. but does it?". If virtual
environments have to look at the vma in order to look at page tables,
that's not possible. They have to be able to work with the page tables
on their own, _without_ any special rules that are private to the
guest.

So I'm not seeing any *use* of pte_numa() in places that would make me
worry, though. So maybe it works.

Linus
--
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/