unexpected chSysHalt of ch version 18.2.0

Discussions and support about ChibiOS/RT, the free embedded RTOS.
askariz
Posts: 1
Joined: Fri Mar 03, 2023 4:06 am

unexpected chSysHalt of ch version 18.2.0

Postby askariz » Fri Mar 03, 2023 4:13 am

I have come across an unexpected chSysHalt which call stack is
chSysHalt@0x08011b56 (\home\askariz\mmc_gnss\zubax_chibios\chibios\os\rt\src\chsys.c:181)
chEvtSignalI@0x08012b06 (\home\askariz\mmc_gnss\zubax_chibios\chibios\os\rt\src\chevents.c:285)
timer_callback@0x0801fdfa (\home\askariz\mmc_gnss\firmware\src\board\board.cpp:76)
gpt_lld_serve_interrupt@0x08014c88 (\home\askariz\mmc_gnss\zubax_chibios\chibios\os\hal\ports\STM32\LLD\TIMv1\gpt_lld.c:887)
VectorB0@0x08014cb0 (\home\askariz\mmc_gnss\zubax_chibios\chibios\os\hal\ports\STM32\LLD\TIMv1\gpt_lld.c:180)
<signal handler called>@0xffffffed (Unknown Source:0)
__WFI@0x08011a82 (\home\askariz\mmc_gnss\zubax_chibios\chibios\os\ext\CMSIS\include\core_cmInstr.h:434)
port_wait_for_interrupt@0x08011a82 (\home\askariz\mmc_gnss\zubax_chibios\chibios\os\rt\ports\ARMCMx\chcore_v7m.h:559)
_idle_thread@0x08011a82 (\home\askariz\mmc_gnss\zubax_chibios\chibios\os\rt\src\chsys.c:72)
_port_thread_start@0x0801037a (Unknown Source:0)


and you can see the code in timer_callback
static void timer_callback(GPTDriver *gptp)
{
(void)gptp;
signal_count_10ms ++;
chSysLockFromISR();
if((signal_count_10ms % 10) == 0)
{
if( extWait_RM3100_Thread != NULL )
{
chEvtSignalI(extWait_RM3100_Thread, board::EVT_MASK_TIMER_10MS);
}

if(extWait_IST8310_Thread != NULL )
{
chEvtSignalI(extWait_IST8310_Thread, board::EVT_MASK_TIMER_10MS);
}
}



my platform is stm32f412ce . any help would be appreciate.
chSysUnlockFromISR();
}

my question is how can be trigger the input args tp is NULL .. cause i have protect when call it .. is so wired.
void chEvtSignalI(thread_t *tp, eventmask_t events) {

chDbgCheckClassI();
chDbgCheck(tp != NULL);

User avatar
Giovanni
Site Admin
Posts: 14458
Joined: Wed May 27, 2009 8:48 am
Location: Salerno, Italy
Has thanked: 1076 times
Been thanked: 922 times
Contact:

Re: unexpected chSysHalt of ch version 18.2.0

Postby Giovanni » Fri Mar 03, 2023 8:18 am

Hi,

You should investigate why tp is NULL, the cause is probably non-obvious, a stack overflow for example.

Said that, 18.x is long unsupported, consider moving to a recent version.

Giovanni


Return to “ChibiOS/RT”

Who is online

Users browsing this forum: No registered users and 3 guests