mvme5500: data transfer rate to and from vme space

Kate Feng feng at bnl.gov
Wed Oct 24 14:13:45 UTC 2012


On 10/23/2012 10:04 PM, rwas wrote:

 > Do you have any experience with using the dma feature in the mvme5500?
 > Can that be used with rtems?

Yes, I had good experience in using DMA on RTEMS-MVME5500 BSP.
DMA transfer should be the same among all the PowerPC boards.

An example file can be downloaded from what I post at 
http://sourceforge.net/projects/rtems-blc/
The relevant file is at mcaR7-1-RTEMS/mcaApp/SISSrc/drvSIS3820.cpp.  
Search for '#ifdef __rtems__'.
There are several important steps:

1.  rtems_semaphore_create(.........., &id)
2.  BSP_VMEDmaSetup(0,BSP_VMEDMA_OPT_THROUGHPUT, VME_AM_EXT_SUP_MBLT, 0);

I sent a patch for VME_AM_EXT_SUP_MBLT to enable 64 bit PCI transfer on 
a VME64 crate.
http://www.rtems.com/ml/rtems-users/2012/june/msg00010.html
Let me know if that makes a difference if you use a VME64 crate.

IIRC, the (original ?) VME_AM_EXT_SUP_MBLT code would run on the VME32 
data bus as well.

3. BSP_VMEDmaInstallISR(0, dmaCallbackC, (void*)this);
4. BSP_VMEDmaStart(0, pci_addr, vme_addr, (count)*sizeof(int));

5. rtems_semaphore_obtain (id, RTEMS_WAIT, TIMEOUT);

6. dmaCallbackC() {
      rtems_semaphore_release(id);
}


Hope this helps.

Cheers,
Kate

On 10/24/2012 03:04 AM, Till Straumann wrote:
> On 10/24/2012 01:41 AM, rwas wrote:
>> Till Straumann wrote:
>>>   Are you really using VME BLTs
>> The answer is "no". Somehow I had it in my head that I was.
>> I appologize.
>>
>>>   (or only repeated single-address
>>>   cycles, e.g., the CPU doing a loop - this can be really slow,
>> Yes, this is what I am doing.
>>
>>>   especially if the universe is configured so that the bus has to be
>>>   re-arbitrated for for each cycle)?
>> Looking at BR3, clearly it is. I was under the impression once a master
>> took the bus, it kept it until someone else asked for it. Clearly wrong.
> That is something you can set in the universe; RTM. Boils down
> to a classical throughput vs. response-time tradeoff. (If you hold
> the bus longer then throughput gets better but it takes longer
> for somone else to get hold of the bus).
>> It is clearly doing an address cycle every word.
>> I put my scope on the backplane and  I'm getting an AS assertion with
>> every DS.
> Yeah. When you use the CPU then you can't do a block transfer
> (obviously).
>> All this with a BR3 for each cycle.
>>
>> Again I apologize, this is a pretty newb kind of error.
>>
>> Do you have any suggestions? Seems like there is no direct RTEMS way to
>> make use of dma.
> There is: <bsp/VMEDMA.h> You can specify the address mode
> the DMA should use and there you can use a BLT mode.
>
> HTH
> - Till
>>
>>
>> Thanks.
>>
>> Robert W.
>>
>>
>>
>
> _______________________________________________
> rtems-users mailing list
> rtems-users at rtems.org
> http://www.rtems.org/mailman/listinfo/rtems-users




More information about the users mailing list