This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CHNL issue-reclaim blocks/timeouts

Other Parts Discussed in Thread: OMAP-L137

On my OMAP-L137 target @ 192 MHz:
DSP core (CCS 3.3.82.13; DSPBIOS 5.41.03.17) performs data collection/digital processing
ARM core (Linux 2.6) transfers data through TCP/IP

On DSP core data are received from sampling logic at sampling rate through synchronous DMA serial transfers,
triggering HW IRQ, whose calbacks perform input data checking/processing.
Sampling rates are 128,256, up to 8192 Hz.
Whichever the sampling rate, DSP core assembles data in 64Hz packets,
then sends the packet to ARM core through DspLink CHNL issue/reclaim  method.
ARM core in turn polls data packet availability through issue/reclaim  method
at substantial rate >> 64 Hz: this of course results in "timeout" errors, until
a packet is actually retrieved.

At lower sampling rates all is ok.
When sampling rate rises, a single overrun appears in serial IRQ, exactly at 64 Hz,
i.e. when the issue/reclaim call is executed on DSP core.

So I need to clearify the following questions:

DSP/BIOS™ LINK - Version 1.61

14.6  CHNL
14.6.1  Typical sequence
1. Issue allocated buffer(s) to the channel(s) created earlier. Usually:
A primed buffer is issued on an output channel to be received by the
remote client on the DSP.
An empty buffer is issued on an input channel to receive the data issued
by remote client on the DSP.
2. Reclaim a buffer on the channel to which a buffer was issued in the
previous step. This is a synchronous operation i.e. the execution of the
client is blocked until the IO operation is successful (or a timeout occurs).

Please note that API reference reports:

EXPORT_API DSP_STATUS CHNL_reclaim  (  IN ProcessorId  procId, IN ChannelId  chnlId, IN Uint32  timeout, IN OUT ChannelIOInfo *  ioReq )

timeout  Timeout value for this operation. Unit of timeout is OS dependent. 

1) The DSP client block affects HW irqs handling ?
2) Which is (roughy) the time required by ARM to reclaim up to 16K words ?
3) Which is the unit of timeout ?

Any other suggestion is appreciated.

Thank you for your attention.

 

 

 

  • The solution, when found, was much simpler than expected.

    The problem was due to c6000 compiler, that will mask general IRQs as long an optimization is performed,

    especially when large memory to memory data transfers are done.

    I my case such data transfers could last more than the 8192 Hz sampling rate period.....

    so that one sampling every 16 ms was lost.

    I find much useful the pragma:

    #pragma FUNC_INTERRUPT_THRESHOLD (dataprocess_get, 1)

    which prevents IRQs masking as long the code for the dataprocess_get function is executed.

    Many thanks to Italy C6000 FAE Massimo Martelli, which took proper attention to my problem.