summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--firmware/export/system.h4
-rw-r--r--firmware/system.c2
-rw-r--r--uisimulator/win32/kernel.c2
3 files changed, 4 insertions, 4 deletions
diff --git a/firmware/export/system.h b/firmware/export/system.h
index 038d9567e0..cfb771d66b 100644
--- a/firmware/export/system.h
+++ b/firmware/export/system.h
@@ -133,7 +133,7 @@ static inline int tas (volatile int *pointer)
/* Compare And Swap */
static inline int cas (volatile int *pointer,int requested_value,int new_value)
{
- unsigned int oldlevel = set_irq_level(15);
+ unsigned int oldlevel = set_irq_level(HIGHEST_IRQ_LEVEL);
if (*pointer == requested_value)
{
*pointer = new_value;
@@ -146,7 +146,7 @@ static inline int cas (volatile int *pointer,int requested_value,int new_value)
static inline int cas2 (volatile int *pointer1,volatile int *pointer2,int requested_value1,int requested_value2,int new_value1,int new_value2)
{
- unsigned int oldlevel = set_irq_level(15);
+ unsigned int oldlevel = set_irq_level(HIGHEST_IRQ_LEVEL);
if (*pointer1 == requested_value1 && *pointer2 == requested_value2)
{
*pointer1 = new_value1;
diff --git a/firmware/system.c b/firmware/system.c
index cd2c5e34a0..41358a6776 100644
--- a/firmware/system.c
+++ b/firmware/system.c
@@ -302,7 +302,7 @@ void (*vbr[]) (void) __attribute__ ((section (".vectors"))) =
void system_reboot (void)
{
- set_irq_level(15);
+ set_irq_level(HIGHEST_IRQ_LEVEL);
asm volatile ("ldc\t%0,vbr" : : "r"(0));
diff --git a/uisimulator/win32/kernel.c b/uisimulator/win32/kernel.c
index 466950eba0..9c82435df2 100644
--- a/uisimulator/win32/kernel.c
+++ b/uisimulator/win32/kernel.c
@@ -86,7 +86,7 @@ void queue_post(struct event_queue *q, int id, void *data)
int wr;
int oldlevel;
- oldlevel = set_irq_level(15);
+ oldlevel = set_irq_level(HIGHEST_IRQ_LEVEL);
wr = (q->write++) & QUEUE_LENGTH_MASK;
q->events[wr].id = id;