On Tue, 10 Jul 2018, Yang, Bin wrote:
> > +    * FIXME:
> > +    * 1) Make this yell loudly if something tries to set a full
> > +    *    large page to something which is not allowed.
> 
> I am trying to work out a patch based on your sample code and
> comments. 
> I do not understand here why it needs to yell loudly if set a full
> large page to something which is not allowed. It can split the large
> page to 4K-pages finally. And static_protection() will also be called
> for 4K-page change. Why not just add warning if 4K-page change is not
> allowed?

Think about it. If there is a large page which contains an area which
requires a different mapping that the one which the large page provides,
then something went wrong _before_ this code is called.

Thanks,

        tglx

Reply via email to