Niklaus,
Here are a few things to check:
1. Your memory destination and source addresses are contiguous. You can get
this using something like:
mem = (void*)__get_free_pages(GFP_KERNEL | GFP_DMA, get_order(size));
2. Your source and dest addresses are _bus_ addresses. You can get these by:
source = virt_to_bus((u32 *)mem);
Also, we had some trouble with the ppc4xx_ functions using 440 - it seems
these functions are specific to the PLB4. So if you are trying to do DMA on
say the PLB peripheral bus on a memory mapped device, you definitely have
some trouble.
I have some code for doing both - so of you need any further help, just ask.
Regards
Jan Reyneke
_________________________________________________________________
Get Hotmail, News, Sport and Entertainment from MSN on your mobile.
http://www.msn.txt4content.com/
Here are a few things to check:
1. Your memory destination and source addresses are contiguous. You can get
this using something like:
mem = (void*)__get_free_pages(GFP_KERNEL | GFP_DMA, get_order(size));
2. Your source and dest addresses are _bus_ addresses. You can get these by:
source = virt_to_bus((u32 *)mem);
The above contradicts an email by Ben H back on 22 Dec:
<http://ozlabs.org/pipermail/linuxppc-embedded/2006-December/025546.html>
But I don't know enough to resolve the conflict...
Tom
--
/"\ ASCII Ribbon Campaign |
\ / | Email to user 'CTZ001'
X Against HTML | at 'email.mot.com'
/ \ in e-mail & news |
Yes, I know - that email is in response to a question I posted. :)
This seems to be one of those ongoing uncertainties. It seems commonly
advocated that you shouldn't use it, but as yet I've found no suitable
alternative.
Some more reading on why you *should* use it:
http://ozlabs.org/pipermail/linuxppc64-dev/2004-March/001276.html
It would be nice if we could get a definitive answer to this. Anyone out
there who knows?
Cheers
Jan Reyneke
_________________________________________________________________
Get Hotmail, News, Sport and Entertainment from MSN on your mobile.
http://www.msn.txt4content.com/
On Sun, Jan 21, 2007 at 09:28:34PM +0000, - Reyneke wrote:
This seems to be one of those ongoing uncertainties. It seems commonly
advocated that you shouldn't use it, but as yet I've found no suitable
alternative.
Really?
Could you elaborate, why API described in Documentation/DMA-API.txt
(e.g. "Streaming DMA mappings") is not suitable for you?.
--
Eugene