On Sun, Nov 20, 2016 at 01:09:08PM +0100, Luca dariz wrote: > Maybe the translation should be done by the pager? > For example, the default pager would deny such requests, while there > could be an "io pager" which handles only contiguous memory objects and > perform the translation.
We don't want pagers, privileged or not, to mess with page tables. These are the responsibility of the kernel. > The main reason of this distinction is that sometimes on rump drivers > the buffer used for I/O is not allocated from contiguous memory. Which is fine. You're not dealing with just contiguous memory here, you want to handle any device memory. > Ok, so memory mapped I/O would work for user-space drivers. > I still have to figure out how this "io pager" should be implemented. > Should it be driver-specific? Or should it ask the specific driver to > fill a specific memory page on demand? It should probably driver-specific, but unless you can cite one example where the memory object pattern doesn't fit, I don't think we need a new RPC. What drivers need to do is request specific physical memory to insert into memory objects, with special properties (uncacheable, wired, etc...), that can then be mapped by users. -- Richard Braun

