summaryrefslogtreecommitdiff
path: root/supervisor/shared/background_callback.c
diff options
context:
space:
mode:
Diffstat (limited to 'supervisor/shared/background_callback.c')
-rw-r--r--supervisor/shared/background_callback.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/supervisor/shared/background_callback.c b/supervisor/shared/background_callback.c
index 288c9a4df..68a0a9667 100644
--- a/supervisor/shared/background_callback.c
+++ b/supervisor/shared/background_callback.c
@@ -33,7 +33,7 @@
#include "supervisor/shared/tick.h"
#include "shared-bindings/microcontroller/__init__.h"
-STATIC volatile background_callback_t *callback_head, *callback_tail;
+STATIC volatile background_callback_t * volatile callback_head, * volatile callback_tail;
#define CALLBACK_CRITICAL_BEGIN (common_hal_mcu_disable_interrupts())
#define CALLBACK_CRITICAL_END (common_hal_mcu_enable_interrupts())
@@ -50,7 +50,6 @@ void background_callback_add_core(background_callback_t *cb) {
cb->prev = (background_callback_t*)callback_tail;
if (callback_tail) {
callback_tail->next = cb;
- cb->prev = (background_callback_t*)callback_tail;
}
if (!callback_head) {
callback_head = cb;