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.

DRA756: HWI processing in SysBIOS on A15 without using the dispatcher

Part Number: DRA756
Other Parts Discussed in Thread: SYSBIOS

On behalf of a customer I moved the below question to the public E2E forum.

For interrupt processing I need minimal latency, meaning no system functions nor wrappers involved.

My question is - how can I configure HWI to run without HWI Dispatcher involved? Can this be somehow configured in SysBIOS or do I have to manipulate IRQ vectors manually to plug my small routine? There should be a way to get it working.

Best regards,

Manfred

  • Hi,

    There is no option in SYSBIOS to disable HWI Dispatcher.

    The only way is to manage interrupt control directly and update interrupt vector table to add ISR and take care of context switching in ISR without the use of HWI APIs from SYSBIOS.

    We don't recommend this.

    However, if you want to do this, you can check CSL in PDK for baremetal code example.

    Regards,
    Stanley

  • I think that there is a way to reconfigure the way SYSBIOS handles interruptions. The A15 uses the ti.sysbios.family.arm.gic.Hwi module, which provides a way to set user-defined function for IRQ Handling:

    Hwi.irqFunc = Void(*)(Void) undefined;

    This of course completely overrides the default Dispatcher, so I would have to call it manually for other IRQs.

    On the other hand, the GIC module provides a way to set the SWI Hander:

    SVC Handler. Supervisor Call exception handler. (previously called Software Interrupt or SWI) Default is an internal exception handler

    Hwi.svcFunc = Void(*)(Void) undefined;

    Could you please tell me whether SWI can be used for the purpose mentioned in the question?

    I need to trigger one A15 core from another and quickly handle the interruption. This is needed for inter-core counters synchronization.

  • Hi,

    As I mentioned, there is no HWI configuration option or API to disable dispatcher.

    If you overwrite the Hwi.irqFunc with your own ISR, all interrupt will trigger that same ISR.

    I assume you will have to do something similar to HWI dispatcher as Hwi_dispatchIRQ in bios_6_46_06_00/packages/ti/sysbios/family/arm/gic/Hwi_asm_gnu.asm.

    Hwi.svcFunc is assigned to the default exception handler, Exception_excHandlerAsm, in bios_6_46_06_00\packages\ti\sysbios\family\arm\exc\Exception_asm_gnu.asm.

    You can rebuild SYSBIOS source so if you want to change the default implementation in SYSBIOS, it is totally up to you.

    Regards,
    Stanley