Hello,
Like many others, I am using the c6678 as a PCIe peripheral and have a linux driver which is able to load and run executable images on the DSP cores.
I have run in to the odd behavior described in the following posts (plus several others):
http://e2e.ti.com/support/dsp/c6000_multi-core_dsps/f/639/t/294703.aspx
http://e2e.ti.com/support/dsp/c6000_multi-core_dsps/f/639/t/327340.aspx
In each case, someone has pointed to the Advantech PCIE driver which contains the following comment:
/*-------------------------------------------------------------------------
* The following code is a work around to flush the cache, without this
* Any dirty cache lines in L1D may cause corruption of the downloaded
* image
*/
The code then proceeds to perform a workaround where a 8 instruction program consisting of only IDLE opcodes is written to 0xc0000000 (MSMCRAM). The DSP cores are then brought out of reset to execute the IDLE loop program, then placed back in reset & have the "real" program loaded.
I am also using this workaround, and it appears to work. I would like answers to the following 2 questions:
1). Is the comment actually correct? Does releasing the DSP core from reset not only invalidate the L1D cache, but actually perform a write-back? Are there other important details/caveats? Is there any more detailed explanation on what is being worked around? an errata document entry?
2) Are there any implicit requirements on the subsequent program that is loaded when using this workaround? For example, should the 1st cache line of MSMCRAM not be used? I'm guessing that it is okay to use, as the "IDLE program" should not cause any entries in L1D during its execution. Correct?
Thanks,
Joel