From: Douglas Gilbert <dougg@torque.net>
To: Steffen Persvold <sp@scali.no>
Cc: linux-kernel@vger.kernel.org
Subject: Re: Short question about the mmap method
Date: Sat, 05 Jan 2002 12:52:12 -0500 [thread overview]
Message-ID: <3C373D4C.417FF31E@torque.net> (raw)
Steffen Persvold <sp@scali.no> wrote:
> 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 ?
Steffen,
I recently implemented the mmap() call in the SCSI generic
(sg) driver. See that driver in lk 2.4.17 or go to
http://www.torque.net/sg
and download version 3.1.22 of the sg driver from the table.
It will run on any kernel in the 2.4 series. It should
answer most of your questions (at least about mmap-ing
memory obtained from __get_free_pages() which is a bit
tricky).
Doug Gilbert
next reply other threads:[~2002-01-05 17:49 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-01-05 17:52 Douglas Gilbert [this message]
-- strict thread matches above, loose matches on Subject: below --
2002-01-04 20:25 Short question about the mmap method Steffen Persvold
2002-01-04 20:59 ` Tommy Reynolds
2002-01-05 1:07 ` Steffen Persvold
2002-01-05 2:56 ` Steffen Persvold
2002-01-05 3:59 ` Steffen Persvold
2002-01-05 14:17 ` Roman Zippel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3C373D4C.417FF31E@torque.net \
--to=dougg@torque.net \
--cc=linux-kernel@vger.kernel.org \
--cc=sp@scali.no \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox