From: u.kleine-koenig@pengutronix.de (Uwe Kleine-König)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 4/5] DMA: Add functions to preallocate DMA memory dor devices
Date: Wed, 15 Sep 2010 09:28:50 +0200 [thread overview]
Message-ID: <20100915072850.GB17325@pengutronix.de> (raw)
In-Reply-To: <20100902105055.GS26319@n2100.arm.linux.org.uk>
Hello,
On Thu, Sep 02, 2010 at 11:50:55AM +0100, Russell King - ARM Linux wrote:
> On Thu, Aug 19, 2010 at 04:40:22PM +0200, Guennadi Liakhovetski wrote:
> > Currently dma_declare_coherent_memory() and dma_release_declared_memory() are
> > provided to assign DMA memory to a device and to release it. These functions
> > can be use with device local memory, like on-chip SRAM. However, they are
> > unsuitable for assigning of generic system RAM to devices, because such system
> > memory should not be ioremapped, and ioremap() is used internally in the former
> > of these functions to map the memory.
> >
> > This patch solves this problem by adding two more functions:
> > dma_preallocate_coherent_memory() and dma_release_preallocated_memory(), which
> > allocate DMA coherent memory and assign it to the device, and release it back
> > respectively.
>
> This looks like a much saner interface for pre-allocating DMA memory from
> system memory, rather than trying to use dma_declare_coherent_memory().
>
> Acked-by: Russell King <rmk+kernel@arm.linux.org.uk>
Acked-by: Uwe Kleine-K?nig <u.kleine-koenig@pengutronix.de>
If this series isn't acceptable for the DMA people, I suggest to add it
locally for ARM if no other solution is found before .36 is released.
Best regards
Uwe
--
Pengutronix e.K. | Uwe Kleine-K?nig |
Industrial Linux Solutions | http://www.pengutronix.de/ |
next prev parent reply other threads:[~2010-09-15 7:28 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-08-19 14:39 [PATCH 0/5] Add API for DMA memory reservation for devices Guennadi Liakhovetski
2010-08-19 14:40 ` [PATCH 1/5] DMA: Remove unneeded "extern" from function declarations Guennadi Liakhovetski
2010-08-19 14:40 ` [PATCH 2/5] DMA: dma_declare_coherent_memory() should return an error if unsupported Guennadi Liakhovetski
2010-08-19 14:40 ` [PATCH 3/5] DMA: reduce the number of memory allocations Guennadi Liakhovetski
2010-08-19 15:35 ` Greg KH
2010-08-19 15:46 ` Guennadi Liakhovetski
2010-08-19 16:02 ` Greg KH
2010-09-14 8:52 ` Paul Mundt
2010-09-15 7:23 ` Guennadi Liakhovetski
2010-09-16 2:58 ` FUJITA Tomonori
2010-09-16 7:04 ` Russell King - ARM Linux
2010-09-16 7:08 ` FUJITA Tomonori
2010-09-16 4:22 ` Paul Mundt
2010-08-20 1:15 ` Michał Nazarewicz
2010-08-19 14:40 ` [PATCH 4/5] DMA: Add functions to preallocate DMA memory dor devices Guennadi Liakhovetski
2010-09-02 10:50 ` Russell King - ARM Linux
2010-09-15 7:28 ` Uwe Kleine-König [this message]
2010-08-19 14:40 ` [PATCH 5/5] SH: use dma_preallocate_coherent_memory() for platform device memory Guennadi Liakhovetski
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=20100915072850.GB17325@pengutronix.de \
--to=u.kleine-koenig@pengutronix.de \
--cc=linux-arm-kernel@lists.infradead.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).