Hi Guys,
I've a small problem here and hopefully you can point me to where I'm going wrong.
First off the problem, we have a DSP/Bios program running on a DM3730 which receives configurations from the ARM side. The control interface runs within a TSK which runs at start up. During the processing of the control messages the TSK will create a buffer with the following line:
bufferPtr = (genericBuffer_st *)MEM_calloc(DDR2, sizeof(genericBuffer_st), GENERIC_BUF_MEM_ALIGN);
however, if SWI and HWIs are running at that moment using SWI_enable(); and C64_enableIER (C64_EINT4); I get the following error: Sys abort called with message '*** MEM lock NOT CALLED IN TSK CONTEXT', but if they are not everything works fine. Oddly, disabling the SWI and HWIs doesn't allow me to allocate the buffer. I've been fighting with this for a while and I've seen some similar problems on the forums, but none that I can apply to this context.
NB, there is no allocation or freeing within the software interrupts, other allocations within the task behave correctly though these are via a C++ new call, rather than MEM_calloc. MEM_alloc has also been tried without success.
Thanks in advance, this has been utterly frustrating.
Paddy