linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Williams <steve@icarus.com>
To: linuxppc-embedded@ozlabs.org
Subject: NO_CACHE and mmaped pages
Date: Fri, 19 Aug 2005 11:44:53 -0700	[thread overview]
Message-ID: <430628A5.7090505@icarus.com> (raw)


I think the answer is "Yes", but I want to get a second opinion.

I need memory that is mapped into user space (so that I can manage
it as a BIG heap) but is not cached by the CPU, a PPC405GPr running
kernel 2.4.30something.

A possible solution is to in my driver support mmap and implement the
nopage function. The pages that I create in the nopage will be allocated
by the consistent_alloc function, which returns pages marked as NO_CACHE,
and so should be uncached.

The question is, "Is this NO_CACHE status/flag preserved when it is
mapped into the user address space? So far as I can see browsing the
do_no_page function in memory.c, that bit is indeed preserved in the
mapping. Am I right?

Alternatively, is there a way to change a region of memory no
unpaged, a la mlock for locking pages? I would rather not keep a
table of page pointers for 256Meg of memory just so I can do a
consistent_free later:-(

-- 
Steve Williams                "The woods are lovely, dark and deep.
steve at icarus.com           But I have promises to keep,
http://www.icarus.com         and lines to code before I sleep,
http://www.picturel.com       And lines to code before I sleep."

                 reply	other threads:[~2005-08-19 18:44 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=430628A5.7090505@icarus.com \
    --to=steve@icarus.com \
    --cc=linuxppc-embedded@ozlabs.org \
    /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;
as well as URLs for NNTP newsgroup(s).