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

Re: how has set_pgdir been replaced in 2.4.x



Hi,

On Mon, Dec 10, 2001 at 01:35:19PM +0100, Martin Frey wrote:
 
> >They are now faulted on demand for vmalloc.  The cost of manually
> >updating all the pgds for every vmalloc is just too expensive if
> >you've got tens of thousands of threads in the system.
> 
> Is there an implication on drivers, e.g. not accessing vmalloc'd
> memory from within a page fault handler? A page fault from a
> page fault handler is quite ugly...

arch/i386/mm/fault.c is where the magic happens.  The vmalloc fault
path is really, really careful not to access any potentially volatile
data, so it is supposed to be safe for use even inside traps and
interrupts.

There _is_ one place where it can break down: if you have a driver
which walks page tables manually after a vmalloc, expecting to
translate virtual addresses into physical ones before the VA has been
faulted in.  Other than that, it should be safe.

Cheers,
 Stephen
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/