tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: UVM and the NULL page



On Mon, Aug 01, 2016 at 03:30:37PM +0000, Eduardo Horvath wrote:
> On Sat, 30 Jul 2016, Joerg Sonnenberger wrote:
> 
> > For what it is worth, I do believe that the handling of the 0 page
> > should be part of UVM and not pmap. I am only objection to forcing it
> > unconditionally.
> 
> I disagree.  Based on the number of files you need to touch it's much 
> better to implement it in pmap.  All you need to do is check the VA in 
> pmap_enter and if it's 0 return an error.  Done.  It only affects the 
> particular architectures that have this problem.  You don't further 
> complicate the UVM code, you don't need to instrument all the different 
> syscall entries, and you don't have to worry about possibly missing some 
> obscure path to get page zero mapped in to some process.

I disagree. While it is nice to assert this property in the pmap, it is
the wrong place. First of all, all pmaps need to be audited, at least on
platforms with shared address space. It's not specific to x86. Second,
part of the problem is that UVM does not handle its own constraints
correctly. That means it is possible that some of the (then failing)
requests could be fulfilled by correct code. In short, handling it in
the pmap doesn't actually solve the problem completely either.

Joerg


Home | Main Index | Thread Index | Old Index