lkml.org 
[lkml]   [2002]   [Jan]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Short question about the mmap method
Uttered "Steffen Persvold" <sp@scali.no>, spoke thus:

> Hi lkml readers,
>
> I have a question regarding drivers implementing the mmap and nopage methods.
> In some references I've read that pages in kernel allocated memory (either
> allocated with kmalloc, vmalloc or__get_free_pages) should be set to reserved
> (mem_map_reserve or set_bit(PG_reserved, page->flags) before they can be
> mmap'ed to guarantee that they can't be swapped out. Is this true ?

[kv]malloc memory is _never_ subject to paging and can be mmap'ed with a
vengeance without resorting to mucking about with marking pages or the like.

You're working too hard ;-)

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- + -- -- -- -- -- -- -- -- -- --
Tommy Reynolds | mailto: <reynolds@redhat.com>
Red Hat, Inc., Embedded Development Services | Phone: +1.256.704.9286
307 Wynn Drive NW, Huntsville, AL 35805 USA | FAX: +1.256.837.3839
Senior Software Developer | Mobile: +1.919.641.2923
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2005-03-22 13:15    [W:0.133 / U:0.124 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site