Enable Dma Channel on Plx9080

Hi all,

Thanks to this forum (especially PaoloC) I’ve
been able to setup a scatter-gather list, translate
it into a plx specific plx descriptors list and write
the the descriptors list address into the plx registers.

Next this to do is to enable and start the dma tranfer.
Somehow it never gets started.

  1. Clear the DMACSR0 register (just to make sure)
    The reg looks like this 00010000 (Hardware sets dmadone bit)
  2. Enable the dma channel (DMACSR0 | 0x01)
    The reg looks like this 00010001
  3. Start the dma channel
    The reg looks like this 00000001 ???

So the hardware clears the dma done bit pretending it’s busy.
The start transfer bit however remains zero.

What could be wrong?

Thanks in advance,

Kind regards,

Roy

In order to do chaining mode DMA you need to perform the following steps
(for channel 0):

  1. Set DMA mode to chaining (bit 9 in the DMAMODE0 register)
  2. Set up the 1st descriptor pointer register to the 1st descriptor
    (DMADPR0). Note that bit 0 for this register (and for each descriptor
    pointer) indicates where the descriptor is (PCI or Local).
  3. Set the enable and Go bits in the DMA command status register (bit 0 and
    bit 1 in the DMACSR0 register). Not that the start bit (1) is not readable.

After starting the DMA, if you can read the DMACSR0 register again (before
the DMA completes) you should see that bit 4 has a value of 1 which
indicates that the DMA has not completed.

There are several other registers that need to be setup correctly. I don’t
have the spec handy at the moment so I can’t tell you what all these
registers are (DMA Threshold, Local Address Space, PCI Command Register,
etc)

Also, if you want interrupts to be generated on completion of DMA or DMA
chains, the appropriate registers need to be set (INTCSR).

  • Steve -

-----Original Message-----
From: xxxxx@chess.nl [mailto:xxxxx@chess.nl]
Sent: Thursday, April 17, 2003 9:15 AM
To: NT Developers Interest List
Subject: [ntdev] Enable Dma Channel on Plx9080

Hi all,

Thanks to this forum (especially PaoloC) I’ve
been able to setup a scatter-gather list, translate
it into a plx specific plx descriptors list and write
the the descriptors list address into the plx registers.

Next this to do is to enable and start the dma tranfer.
Somehow it never gets started.

  1. Clear the DMACSR0 register (just to make sure)
    The reg looks like this 00010000 (Hardware sets dmadone bit)
  2. Enable the dma channel (DMACSR0 | 0x01)
    The reg looks like this 00010001
  3. Start the dma channel
    The reg looks like this 00000001 ???

So the hardware clears the dma done bit pretending it’s busy.
The start transfer bit however remains zero.

What could be wrong?

Thanks in advance,

Kind regards,

Roy


You are currently subscribed to ntdev as: xxxxx@cognex.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

Hi Steve,

Thanks for you reply.
I think I’ve setup everything correct.
I’ve must have missed something so the
DMA transfer does not start.

Only thing I’m not certain about is whether
or not the plx descriptor list is in PCI address
space. How do I make sure it is?
Any tool available to see in which space a buffer
is placed?

I have the specs handy. Do you (or anyone) have
a good sample of configuring a plx9080 (or other plx chip)
for chaining dma?

Thanks again,

Kind regards,

Roy

The descriptors are in PCI address space if they are external to your
hardware (system memory, another device, etc). They are in local space if
you device has memory on the local bus of the 9080.

  • Steve -

-----Original Message-----
From: xxxxx@chess.nl [mailto:xxxxx@chess.nl]
Sent: Thursday, April 17, 2003 5:22 PM
To: NT Developers Interest List
Subject: [ntdev] RE: Enable Dma Channel on Plx9080

Hi Steve,

Thanks for you reply.
I think I’ve setup everything correct.
I’ve must have missed something so the
DMA transfer does not start.

Only thing I’m not certain about is whether
or not the plx descriptor list is in PCI address
space. How do I make sure it is?
Any tool available to see in which space a buffer
is placed?

I have the specs handy. Do you (or anyone) have
a good sample of configuring a plx9080 (or other plx chip)
for chaining dma?

Thanks again,

Kind regards,

Roy


You are currently subscribed to ntdev as: xxxxx@cognex.com
To unsubscribe send a blank email to xxxxx@lists.osr.com