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.
Hey guys,
in our System, which is built on top of the TMS570LS3137, we have configured several IRQs and exactly 2 FIQs (except ESM HL).
In some certain cases, we need to disable the two FIQs temporarily when operations on shared data are ongoing. We are doing this by writing the two related bits in the VIMs appropriate REQENACLR register. When reactivating the two FIQs, we're doing this by writing to the REQENASET register. Most of the time this works perfectly fine.
Rather infrequently it happens, that a phantom interrupt is being asserted while the previous context is standing right behind the instruction that performs the disabling of the FIQs. In my opinion, any of the FIQs gets pending right at the same point in time when the STR instruction to the VIM REQENACLR register is being performed.
I already had a look at www.ti.com/.../spna063.pdf.
I think that this is very related to our issue.
The problem is just, that we cannot use the suggested solution since the FIQs cannot be disabled globally. This was the reason why we decided to mask them via the VIM.
Do you know any good solution, on how to temporarily disable FIQs without the need to deal with possible phantom interrupt assertions?
Do we also need to take the peripheral into account when doing this temporal masking?
Thanks in advance.
Kind regards,
Michael
Michael,
The only other way to avoid phantom interrupts in this context I can imagine, is to mask the FIQ lines in FIQ mode.
This could be achieved by triggering a "special" FIQ via SW, or by switching from another operating mode (SuperVisor or System) into FIQ mode.
In that case FIQ's are disabled and thus masking should not cause problems in terms of phantom interrupts.
CPU mode changes can be done with the help of the CPS instruction or SVC handlers.
Best Regards,
Christian