From: Niklaus Giger <niklaus.giger@member.fsf.org>
To: "- Reyneke" <reynekejunk@hotmail.com>
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: Howto use PPC4xx memory to memory DMA
Date: Fri, 19 Jan 2007 21:47:27 +0100 [thread overview]
Message-ID: <200701192147.27340.niklaus.giger@member.fsf.org> (raw)
In-Reply-To: <BAY7-F81C4E9CDFE4D0599271E7BEA90@phx.gbl>
Am Freitag, 19. Januar 2007 10:35 schrieb - Reyneke:
> Ooh - and the 3d thing - cache coherence. I.e.:
>
> dma_cache_inv((u32)mem, (u32)nBytes);
>
> >>Here are a few things to check:
Thanks a lot for your tips. First I called
a) __get_free_pages(GFP_KERNEL | GFP_DMA, get_order(size));
for the source and destination address.
Then before calling ppc4xx_enable_dma I added
b) ppc4xx_set_src_addr(DMA_NR, virt_to_bus(src));
c) ppc4xx_set_src_addr(DMA_NR, virt_to_bus(dst));
d) flush_dcache_all();
With these changes I got at least one byte copied. After fixing the
ppc4xx_enable_dma everything worked fine. (Patch posted a few minutes ago.)
Did you manage to use DMA on PLB peripheral bus on a memory mapped dev? I
think there one should also increment the source or destination address. But
I have no example HW/code at hand to test these two cases too.
Best regards
--
Niklaus Giger
next prev parent reply other threads:[~2007-01-19 20:47 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-01-19 9:35 Howto use PPC4xx memory to memory DMA - Reyneke
2007-01-19 20:47 ` Niklaus Giger [this message]
-- strict thread matches above, loose matches on Subject: below --
2008-01-07 10:57 padmanabha
2007-01-19 22:32 Alexis Berlemont
2007-01-21 19:47 ` Eugene Surovegin
2007-01-19 8:49 - Reyneke
2007-01-19 19:48 ` T Ziomek
2007-01-21 21:28 ` - Reyneke
2007-01-22 17:18 ` Eugene Surovegin
2007-01-18 22:16 Niklaus Giger
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=200701192147.27340.niklaus.giger@member.fsf.org \
--to=niklaus.giger@member.fsf.org \
--cc=linuxppc-embedded@ozlabs.org \
--cc=reynekejunk@hotmail.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.