Re: VM: Bizzare MM tricks...

From: Karim Yaghmour (karym@opersys.com)
Date: Wed Apr 26 2000 - 23:17:27 EST


Jeff Garzik wrote:
> what's wrong with remap_page_range? that's traditionally how mmap of
> arbitrary kernel space is done in char drivers and such. and single
> remap_page_range is typically called once per page, there should be no
> problem at all mapping discontiguous memory into a contiguous userland
> virtual address space...

I wrote about this a couple of weeks ago on the mailing list but never got
an answer. remap_page_range will _NOT_ work if you try to map pages allocated by
__get_free_pages onto user space. You _NEED_ to use the PG_reserved bit.
Otherwise remap_page_range fails. Ashok is right on this one. Once the
PG_reserved bit is set though, remap_page_range will work fine.

Karim

===================================================
                 Karim Yaghmour
               karym@opersys.com
          Operating System Consultant
 (Linux kernel, real-time and distributed systems)
===================================================

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sun Apr 30 2000 - 21:00:12 EST