CSL_srioLsuSetup and SRIO

I have a C6474 evm board with two seperate CPU that are connected together through SRIO Port 1. I have found a pretty nice example of doing Direct I/O using the CSL API that I understand pretty much everything in it now (at a high level of course). One thing that I don't quite understand is this section of code...


    for(index=0; index<0x10000; index++) {
    /* Configure the LSU1 and start transmission */
    lsu_no = SELECTED_LSU;
    CSL_srioLsuSetup (hSrio, &lsu_conf, lsu_no);

    /* Wait for the completion of transfer */
    response.index = lsu_no;
    do {
        CSL_srioGetHwStatus (hSrio, CSL_SRIO_QUERY_LSU_BSY_STAT, &response);
    }while(response.data == 1);


Notice the for loop goes 0x10000 times. I figured this meant that it was sending the message 0x10000 times. So when I removed the for loop (or reduced it to 1) the transfer is never received on the Target side. Anybody have any insight on why the transfer wouldn't make it across the link without sending it a couple times. I've noticed that I can reduce the for loop to 5 times and then it will make it but anything less it doesn't.





  • Hi Josh

    I was able to set the loop to 0x1 and have it work. Check your memory map. Mine had the shared buffer pointer set as

    #define DST ((Uint8 *)0x1088d000)

    Then look at your .map file. In my build, L2 is almost used up and may have overflowed into the memory used for the target SRIO buffer 0x1088d000. You may have to move that buffer to a new location if you added more code.


             name            origin    length      used     unused   attr    fill
    ----------------------  --------  ---------  --------  --------  ----  --------
      VECS                  00e00000   00000200  00000000  00000200  RWIX
      L1P                   00e00200   00007dff  00000000  00007dff  RWIX
      L1D                   00f00000   00007fff  00000000  00007fff  RWIX
      L2                    10880000   001effff  0000cd20  001e32df  RWIX
      SDRAM                 80000000   00800000  00000000  00800000  RWIX

    I changed the link.cmd to seperate all sections from the L2 used for the SRIO buffer.

       /* Use global addresses for L2 */
       L2:      o=0x10800000 l=0x0080000   // core 0 L2
       L2_SRIO: o=0x10880000 l=0x0080000   // core 0 L2 For SRIO buffers.


  • In reply to Eddie3909:

    Thank you,


    I haven't looked at this problem for a long time, but its good to know you got it working.



  • In reply to Joshua Hintze:

    dear community

    i m really in SRIO and i don't know how to handle a real difficult situation.in fact, i wanted to  create a library and i ve added 3 file .c but when i build the project

    i have this error and i don't know what does it mean!!

    ----------------------------  tarik.pjt - Debug  -----------------------------
    [LSU_configtrans.c] "C:\CCStudio_v3.3\C6000\cgtools\bin\cl6x" -g -pdsw225 -fr"C:/CCStudio_v3.3/boards/evmc6474_v1/csl_C64742/example/srio/essai/tarik/Debug" -d"_DEBUG" -mv6400 -@"../../essai/tarik/Debug.lkf" "LSU_configtrans.c"
    "C:/CCStudio_v3.3/C6000/csl/include/csl_chiphal.h", line 267: fatal error: #error NO CHIP DEFINED (use -dCHIP_XXXX where XXXX is chip number, i.e. 6201)
    1 fatal error detected in the compilation of "LSU_configtrans.c".
    Compilation terminated.


    what can i do to overcome this situation?


  • In reply to tarik taro:


    What its meant to me is that CCS pre-processor includes are not pointing to the CSL package for your device.

    Also check to see what device is defined. i.e. CHIP_C6474, CHIP_C6472, etc.



  • In reply to Eddie3909:


    thanks for your advice,the probleme is resolved.in fact ,the CCS pre-processor was not pointing to the CSL package.



  • In reply to tarik taro:


    how to configure BIOS/DSP for c6474 by using rtdx and srio. Example of CSL srio c6474 does not includes BIOS/DSP configure, I want to use new configure and link.cmd for RTDX, BIOS.

    if i use configure BIOS/DSP of swi examples at C:\CCStudio_v3.3\bios_5_33_01\packages\ti\bios\examples\basic\swi\evm6747, the SRIO is not to work.


  • In reply to le oanh:

    Hi Le

    Use the DIO library instead. Its pretty easy to use.


    There are examples that are very helpful in the lib. Also check the DIO library html documentation in \doc\html\main.html and click on the modules tab, then select TST. You'll get a complete list of the example code.