tech-kern archive

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

Re: drivers customizing mmap(2)

The basic rule is, VM object (FreeBSD's vm_object or NetBSD's uvm_object) owns manageable pages, whose descriptors (vm_page) are returned by getpages() method to fault handler.

If a device only owns device memory (!= manageable pages, thus no vm_page allocated), what to return to fault handler?

My understanding is, FreeBSD uses "fictitious" vm_page, only to tell fault handler the faulting page's physical address (maybe with some other properties).  "Fictitious" way would work, but ugly IMO.

On Wed, Mar 6, 2013 at 2:34 PM, David Young <> wrote:
On Wed, Mar 06, 2013 at 12:12:10PM +0900, Masao Uebayashi wrote:
> vm_object containing ... what?  DMA memory?  Device's memory?

Containing whatever the driver requires.  DMA-able memory, device
registers, wired kernel memory.


David Young    Urbana, IL    (217) 721-9981

Home | Main Index | Thread Index | Old Index