Hi,
what could be a reason of chSysHalt("SV#8") inside STM32_DMA1_CH3_HANDLER (STM32F427)?
chSysHalt("SV#8") at Vector78
Moderators: RoccoMarco, barthess
- Giovanni
- Site Admin
- Posts: 14457
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1076 times
- Been thanked: 922 times
- Contact:
Re: chSysHalt("SV#8") at Vector78
Hi,
It could be something wrong done in the DMA callback or an invalid priority assigned to the DMA interrupt.
Giovanni
It could be something wrong done in the DMA callback or an invalid priority assigned to the DMA interrupt.
Giovanni
Re: chSysHalt("SV#8") at Vector78
Hi,
how to investigate it? I have SV#8 at VectorB0 (ST TIM2) as well.
how to investigate it? I have SV#8 at VectorB0 (ST TIM2) as well.
Vitaly
- Giovanni
- Site Admin
- Posts: 14457
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1076 times
- Been thanked: 922 times
- Contact:
Re: chSysHalt("SV#8") at Vector78
Are you using a different build system / startup files / something else?
Giovanni
Giovanni
Re: chSysHalt("SV#8") at Vector78
Just trying to run CycloneTCP....
Makefile:
# Startup files.
include $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk/startup_stm32f4xx.mk
LDSCRIPT= $(STARTUPLD)/STM32F427xI.ld
/*
* ST32F427xI memory setup.
* Note: Use of ram1, ram2 and ram3 is mutually exclusive with use of ram0.
*/
MEMORY
{
flash0 : org = 0x08000000, len = 1M
flash1 : org = 0x08100000, len = 1M
flash2 : org = 0x00000000, len = 0
flash3 : org = 0x00000000, len = 0
flash4 : org = 0x00000000, len = 0
flash5 : org = 0x00000000, len = 0
flash6 : org = 0x00000000, len = 0
flash7 : org = 0x00000000, len = 0
ram0 : org = 0x20000000, len = 192k /* SRAM1 + SRAM2 + SRAM3 */
ram1 : org = 0x20000000, len = 112k /* SRAM1 */
ram2 : org = 0x2001C000, len = 16k /* SRAM2 */
ram3 : org = 0x20020000, len = 64k /* SRAM3 */
ram4 : org = 0x10000000, len = 64k /* CCM SRAM */
ram5 : org = 0x40024000, len = 4k /* BCKP SRAM */
ram6 : org = 0x00000000, len = 0
ram7 : org = 0x00000000, len = 0
}
Makefile:
# Startup files.
include $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk/startup_stm32f4xx.mk
LDSCRIPT= $(STARTUPLD)/STM32F427xI.ld
/*
* ST32F427xI memory setup.
* Note: Use of ram1, ram2 and ram3 is mutually exclusive with use of ram0.
*/
MEMORY
{
flash0 : org = 0x08000000, len = 1M
flash1 : org = 0x08100000, len = 1M
flash2 : org = 0x00000000, len = 0
flash3 : org = 0x00000000, len = 0
flash4 : org = 0x00000000, len = 0
flash5 : org = 0x00000000, len = 0
flash6 : org = 0x00000000, len = 0
flash7 : org = 0x00000000, len = 0
ram0 : org = 0x20000000, len = 192k /* SRAM1 + SRAM2 + SRAM3 */
ram1 : org = 0x20000000, len = 112k /* SRAM1 */
ram2 : org = 0x2001C000, len = 16k /* SRAM2 */
ram3 : org = 0x20020000, len = 64k /* SRAM3 */
ram4 : org = 0x10000000, len = 64k /* CCM SRAM */
ram5 : org = 0x40024000, len = 4k /* BCKP SRAM */
ram6 : org = 0x00000000, len = 0
ram7 : org = 0x00000000, len = 0
}
Last edited by vrollei on Thu Jan 25, 2018 4:31 pm, edited 1 time in total.
Vitaly
- Giovanni
- Site Admin
- Posts: 14457
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1076 times
- Been thanked: 922 times
- Contact:
Re: chSysHalt("SV#8") at Vector78
Probably yes, that osCreateTask() calls I-class and S-class functions without a critical zone.
Giovanni
Giovanni
Re: chSysHalt("SV#8") at Vector78
It seems that problems are related to thread created by this function:
Code: Select all
osCreateTask(const char_t *name, OsTaskCode taskCode,
void *params, size_t stackSize, int_t priority)
{
void *wa;
thread_t *tp;
stackSize *= sizeof(uint_t);
wa = osAllocMem(THD_WORKING_AREA_SIZE(stackSize));
chSysLock()
thread_descriptor_t td = {name, THD_WORKING_AREA_BASE(wa), THD_WORKING_AREA_BASE(wa) + THD_WORKING_AREA_SIZE(stackSize) / sizeof (stkalign_t), priority, (tfunc_t) taskCode, params};
tp = chThdCreateI(&td)
chSchRescheduleS();
chSysUnlock();
}
Vitaly
Re: chSysHalt("SV#8") at Vector78
Hi,
why chSchWakeupS can fail in chDbgAssert((ch.rlist.current->prio >= ch.rlist.queue.next->prio), "priority order violation") here:
Thread has HIGHPRIO.
Is this the correct calculation of working area end address:
why chSchWakeupS can fail in chDbgAssert((ch.rlist.current->prio >= ch.rlist.queue.next->prio), "priority order violation") here:
Code: Select all
thread_t *tp = chThdCreateI(&td);
chSchWakeupS(&tp, MSG_OK);
Thread has HIGHPRIO.
Is this the correct calculation of working area end address:
Code: Select all
THD_WORKING_AREA_BASE(wa) + THD_WORKING_AREA_SIZE(stackSize) / sizeof (stkalign_t)
Code: Select all
thread_descriptor_t td = {name, THD_WORKING_AREA_BASE(wa), THD_WORKING_AREA_BASE(wa) + THD_WORKING_AREA_SIZE(stackSize) / sizeof (stkalign_t), priority, (tfunc_t) taskCode, params};
Vitaly
Who is online
Users browsing this forum: No registered users and 45 guests