linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: James Bottomley <James.Bottomley@HansenPartnership.com>
To: Bob Liu <lliubbo@gmail.com>
Cc: Tony Prisk <linux@prisktech.co.nz>, Mel Gorman <mgorman@suse.de>,
	linux-mm@kvack.org,
	Arm Kernel Mailing List <linux-arm-kernel@lists.infradead.org>,
	Arnd Bergmann <arnd@arndb.de>
Subject: Re: dma_alloc_coherent fails in framebuffer
Date: Tue, 16 Oct 2012 07:41:41 -0700	[thread overview]
Message-ID: <1350398501.2532.12.camel@dabdike> (raw)
In-Reply-To: <CAA_GA1cPE+m8N1LQA2iOym4jbFwcHG+K2p-3iBovPWuf1N1q+g@mail.gmail.com>

On Tue, 2012-10-16 at 10:17 +0800, Bob Liu wrote:
> I think you need to declare that memory using
> dma_declare_coherent_memory() before
> alloc_from_coherent.

This isn't true.  Almost every platform has a mechanism for
manufacturing coherent memory (in the worst case, they just turn off the
CPU cache on a page and hand it out).  The purpose of
dma_declare_coherent_memory() is to allow a per device declaration of
preferred regions ... usually because they reside either on the fast
path to the device or sometimes on the device itself.  There are only a
handful of devices which need it, so in the ordinary course of events,
dma_alloc_coherent() is used without any memory declaration.

James


--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  parent reply	other threads:[~2012-10-16 14:41 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1350192523.10946.4.camel@gitbox>
2012-10-14 20:34 ` dma_alloc_coherent fails in framebuffer Tony Prisk
2012-10-14 22:26   ` Tony Prisk
2012-10-15  6:42     ` Tomasz Figa
2012-10-15  8:03       ` Tony Prisk
2012-10-15 13:35         ` Marek Szyprowski
2012-10-15  9:45   ` Mel Gorman
2012-10-15 18:28     ` Tony Prisk
2012-10-16  2:17       ` Bob Liu
2012-10-16  5:02         ` Tony Prisk
2012-10-16  5:54         ` Tony Prisk
2012-10-16  6:50           ` Tony Prisk
2012-10-16  7:58             ` Mel Gorman
2012-10-16  8:13               ` Tony Prisk
2012-10-16 14:41         ` James Bottomley [this message]
2012-10-17  2:26           ` Bob Liu

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=1350398501.2532.12.camel@dabdike \
    --to=james.bottomley@hansenpartnership.com \
    --cc=arnd@arndb.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-mm@kvack.org \
    --cc=linux@prisktech.co.nz \
    --cc=lliubbo@gmail.com \
    --cc=mgorman@suse.de \
    /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).