This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Forced Hardfault (INVPC) Exception Error

Using ARM coretx-M chip set

Getting random  INVPC hard fault exception error, while running iperf tool for measuring n/w throughput.

Hard fault reg: 0x40000000

xPSR: 0x01000000

PRIMASK: 0x00000001

CONTROL: 0x00000000

Please help to find the possible root cause.

Parents
  • Assumed that you are using Cortex-M3/M4/M7, there are a number of possible reasons:

    - corruption of EXC_RETURN during interrupt handling. This could be caused by stack corruption, or incorrectly implemented context switching code.

    - corruption of stacked PSR during interrupt handling. This can lead to incorrect IPSR or ICI/IT which can both result in INVPC,

    - Incorrect use of VECTCLRACTIVE bit / SCB->SHCSR that cleared the active status of an interrupt which is still running.

    regards,

    Joseph

Reply
  • Assumed that you are using Cortex-M3/M4/M7, there are a number of possible reasons:

    - corruption of EXC_RETURN during interrupt handling. This could be caused by stack corruption, or incorrectly implemented context switching code.

    - corruption of stacked PSR during interrupt handling. This can lead to incorrect IPSR or ICI/IT which can both result in INVPC,

    - Incorrect use of VECTCLRACTIVE bit / SCB->SHCSR that cleared the active status of an interrupt which is still running.

    regards,

    Joseph

Children