Skip to content

Commit c454cb9

Browse files
committed
fixing NVIC RETTOBASE behavior. The semantics had previously been inverted.
1 parent 075dbb5 commit c454cb9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

harness/fuzzware_harness/native/core_peripherals/cortexm_nvic.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -544,7 +544,7 @@ static uint32_t calc_icsr() {
544544
res |= (nvic.pending_irq << SCB_ICSR_VECTPENDING_Pos) & SCB_ICSR_VECTPENDING_Msk;
545545

546546
// RETTOBASE
547-
res |= (nvic.num_active > 1) << SCB_ICSR_RETTOBASE_Pos;
547+
res |= (nvic.num_active <= 1) << SCB_ICSR_RETTOBASE_Pos;
548548

549549
// VECTACTIVE
550550
res |= nvic.active_irq & SCB_ICSR_VECTACTIVE_Msk;

0 commit comments

Comments
 (0)