niXforums Forum Index
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   PreferencesPreferences   Log in to check your private messagesLog in to check your private messages   Log inLog in 
·  nixdoc.net ·  man pages ·  Linux HOWTOs ·  FreeBSD Tips ·  Forums
navigation Forum index » *nix » Linux » powerpc
ppc4xx_dma example
Post new topic   Reply to topic Page 1 of 1 [5 Posts] View previous topic :: View next topic
Author Message
jlange@y2038.com
*nix forums beginner


Joined: 30 May 2006
Posts: 3

PostPosted: Tue May 30, 2006 11:15 pm    Post subject: ppc4xx_dma example Reply with quote

Hello,
I'm looking for example code that uses the ppc4xx_dma module. Can
anyone point me in the right direction?

Thanks in advance,
John
Back to top
Mark Odell
*nix forums beginner


Joined: 16 Mar 2005
Posts: 40

PostPosted: Wed May 31, 2006 1:00 pm    Post subject: Re: ppc4xx_dma example Reply with quote

jlange@y2038.com wrote:
Quote:
Hello,
I'm looking for example code that uses the ppc4xx_dma module. Can
anyone point me in the right direction?

Do you have a specific question? Are you using the 405 or 440 series?
They differ enough to matter. The PPC Linux sources have DMA code but
it's not exactly a HOW-TO of DMA. The AMCC user manuals for the 405 and
440 are pretty good - I wrote my working drivers from them so it can't
be too hard.
--
- Mark
Back to top
jlange@y2038.com
*nix forums beginner


Joined: 30 May 2006
Posts: 3

PostPosted: Wed May 31, 2006 1:16 pm    Post subject: Re: ppc4xx_dma example Reply with quote

Mark Odell wrote:
Quote:
jlange@y2038.com wrote:
Hello,
I'm looking for example code that uses the ppc4xx_dma module. Can
anyone point me in the right direction?

Do you have a specific question? Are you using the 405 or 440 series?
They differ enough to matter. The PPC Linux sources have DMA code but
it's not exactly a HOW-TO of DMA. The AMCC user manuals for the 405 and
440 are pretty good - I wrote my working drivers from them so it can't
be too hard.
--
- Mark

I'm using the 440 series. I'm just looking for something that shows
how to use the existing ppc4xx_dma module in Linux the way it's
intended to be used rather than starting at the register level
directly.
John
Back to top
Mark Odell
*nix forums beginner


Joined: 16 Mar 2005
Posts: 40

PostPosted: Wed May 31, 2006 1:23 pm    Post subject: Re: ppc4xx_dma example Reply with quote

jla...@y2038.com wrote:
Quote:
Mark Odell wrote:
jlange@y2038.com wrote:
Hello,
I'm looking for example code that uses the ppc4xx_dma module. Can
anyone point me in the right direction?

Do you have a specific question? Are you using the 405 or 440 series?
They differ enough to matter. The PPC Linux sources have DMA code but
it's not exactly a HOW-TO of DMA. The AMCC user manuals for the 405 and
440 are pretty good - I wrote my working drivers from them so it can't
be too hard.
--
- Mark

I'm using the 440 series. I'm just looking for something that shows
how to use the existing ppc4xx_dma module in Linux the way it's
intended to be used rather than starting at the register level
directly.

Oh, so you are using Linux. Do you intend to do scatter/gather or
"single-shot" DMA transfers? For S/G you need to provide a list of
physical pages whereas the single-shot mode you supply a single
physically contiguous buffer.

The concept of DMA on the 440 are simple. Set up the channel, e.g.
periph-to-mem, 4 byte periph. width, buffer enable, dest addr
(physical), chip timing for periph., burst size, and interrupt enables.
Then tell the driver to set up the S/G list or program the DMA
registers to "arm" the DMA. When the peripheral requests the DMA the
process will start. For mem-to-periph it's pretty similar, just the
other way.
--
- Mark
Back to top
jlange@y2038.com
*nix forums beginner


Joined: 30 May 2006
Posts: 3

PostPosted: Wed May 31, 2006 10:05 pm    Post subject: Re: ppc4xx_dma example Reply with quote

Mark Odell wrote:
Quote:
jla...@y2038.com wrote:
Mark Odell wrote:
jlange@y2038.com wrote:
Hello,
I'm looking for example code that uses the ppc4xx_dma module. Can
anyone point me in the right direction?

Do you have a specific question? Are you using the 405 or 440 series?
They differ enough to matter. The PPC Linux sources have DMA code but
it's not exactly a HOW-TO of DMA. The AMCC user manuals for the 405 and
440 are pretty good - I wrote my working drivers from them so it can't
be too hard.
--
- Mark

I'm using the 440 series. I'm just looking for something that shows
how to use the existing ppc4xx_dma module in Linux the way it's
intended to be used rather than starting at the register level
directly.

Oh, so you are using Linux. Do you intend to do scatter/gather or
"single-shot" DMA transfers? For S/G you need to provide a list of
physical pages whereas the single-shot mode you supply a single
physically contiguous buffer.

The concept of DMA on the 440 are simple. Set up the channel, e.g.
periph-to-mem, 4 byte periph. width, buffer enable, dest addr
(physical), chip timing for periph., burst size, and interrupt enables.
Then tell the driver to set up the S/G list or program the DMA
registers to "arm" the DMA. When the peripheral requests the DMA the
process will start. For mem-to-periph it's pretty similar, just the
other way.
--
- Mark

Agreed, but that's not really what I'm asking. I'm trying to figure out
how to use the *ppc4xx_dma module* as the a general-purpose DMA
interface for a ppc440GX-based board (running Linux) rather than
writing one from scratch (why re-invent the wheel?). I'll be using both
S/G or single-shot DMAs, but an example of how to use the ppc4xx_dma
module with either would be greatly appreciated.
John
Back to top
Google

Back to top
Display posts from previous:   
Post new topic   Reply to topic Page 1 of 1 [5 Posts] View previous topic :: View next topic
The time now is Wed Dec 03, 2008 1:40 am | All times are GMT
navigation Forum index » *nix » Linux » powerpc
Jump to:  


Credit Cards | Per Insurance | Credit Cards | MPAA | Share Prices
Copyright © 2004-2005 DeniX Solutions SRL
 
Other DeniX Solutions sites: Unix/Linux blog |  electronics forum |  medicine forum |  science forum | 
Privacy Policy


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.2235s ][ Queries: 11 (0.1411s) ][ GZIP on - Debug on ]