Rename irqenable() to up_irq_enable(); rename irqdisable() to up_irq_disable()

This commit is contained in:
Gregory Nutt
2016-02-14 16:54:09 -06:00
parent 83bc1c97c3
commit 666cc280f4
24 changed files with 40 additions and 40 deletions
+4 -4
View File
@@ -251,8 +251,8 @@ static inline void setprimask(uint32_t primask)
/* Disable IRQs */ /* Disable IRQs */
static inline void irqdisable(void) inline_function; static inline void up_irq_disable(void) inline_function;
static inline void irqdisable(void) static inline void up_irq_disable(void)
{ {
__asm__ __volatile__ ("\tcpsid i\n"); __asm__ __volatile__ ("\tcpsid i\n");
} }
@@ -281,8 +281,8 @@ static inline irqstate_t up_irq_save(void)
/* Enable IRQs */ /* Enable IRQs */
static inline void irqenable(void) inline_function; static inline void up_irq_enable(void) inline_function;
static inline void irqenable(void) static inline void up_irq_enable(void)
{ {
__asm__ __volatile__ ("\tcpsie i\n"); __asm__ __volatile__ ("\tcpsie i\n");
} }
+1 -1
View File
@@ -361,7 +361,7 @@ static inline irqstate_t up_irq_save(void)
/* Enable IRQs and return the previous IRQ state */ /* Enable IRQs and return the previous IRQ state */
static inline irqstate_t irqenable(void) static inline irqstate_t up_irq_enable(void)
{ {
unsigned int cpsr; unsigned int cpsr;
+4 -4
View File
@@ -246,8 +246,8 @@ static inline void setbasepri(uint32_t basepri)
/* Disable IRQs */ /* Disable IRQs */
static inline void irqdisable(void) inline_function; static inline void up_irq_disable(void) inline_function;
static inline void irqdisable(void) static inline void up_irq_disable(void)
{ {
#ifdef CONFIG_ARMV7M_USEBASEPRI #ifdef CONFIG_ARMV7M_USEBASEPRI
setbasepri(NVIC_SYSH_DISABLE_PRIORITY); setbasepri(NVIC_SYSH_DISABLE_PRIORITY);
@@ -289,8 +289,8 @@ static inline irqstate_t up_irq_save(void)
/* Enable IRQs */ /* Enable IRQs */
static inline void irqenable(void) inline_function; static inline void up_irq_enable(void) inline_function;
static inline void irqenable(void) static inline void up_irq_enable(void)
{ {
setbasepri(0); setbasepri(0);
__asm__ __volatile__ ("\tcpsie i\n"); __asm__ __volatile__ ("\tcpsie i\n");
+1 -1
View File
@@ -361,7 +361,7 @@ static inline irqstate_t up_irq_save(void)
/* Enable IRQs and return the previous IRQ state */ /* Enable IRQs and return the previous IRQ state */
static inline irqstate_t irqenable(void) static inline irqstate_t up_irq_enable(void)
{ {
unsigned int cpsr; unsigned int cpsr;
+1 -1
View File
@@ -180,7 +180,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
(void)irqenable(); (void)up_irq_enable();
#endif #endif
a1x_dumpintc("initial", 0); a1x_dumpintc("initial", 0);
+1 -1
View File
@@ -471,7 +471,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -443,7 +443,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
#ifndef CONFIG_SUPPRESS_INTERRUPTS #ifndef CONFIG_SUPPRESS_INTERRUPTS
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -250,7 +250,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -246,7 +246,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -415,7 +415,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
#ifndef CONFIG_SUPPRESS_INTERRUPTS #ifndef CONFIG_SUPPRESS_INTERRUPTS
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -421,7 +421,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
#ifndef CONFIG_SUPPRESS_INTERRUPTS #ifndef CONFIG_SUPPRESS_INTERRUPTS
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -242,7 +242,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -490,7 +490,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -566,7 +566,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
(void)irqenable(); (void)up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -198,7 +198,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -490,7 +490,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -414,7 +414,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -524,7 +524,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -490,7 +490,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts */ /* And finally, enable interrupts */
irqenable(); up_irq_enable();
#endif #endif
} }
+1 -1
View File
@@ -190,7 +190,7 @@ void up_irqinitialize(void)
/* And finally, enable interrupts globally */ /* And finally, enable interrupts globally */
irqenable(); up_irq_enable();
#endif #endif
} }
+2 -2
View File
@@ -160,12 +160,12 @@ static inline void putsreg(irqstate_t sreg)
/* Interrupt enable/disable */ /* Interrupt enable/disable */
static inline void irqenable() static inline void up_irq_enable()
{ {
asm volatile ("sei" ::); asm volatile ("sei" ::);
} }
static inline void irqdisable() static inline void up_irq_disabled()
{ {
asm volatile ("cli" ::); asm volatile ("cli" ::);
} }
+4 -4
View File
@@ -525,14 +525,14 @@ static inline irqstate_t up_irq_save(void)
/* Disable IRQs */ /* Disable IRQs */
static inline void irqdisable(void) static inline void up_irq_disable(void)
{ {
uint32_t flags = __getsr(); uint32_t flags = __getsr();
__setsr(flags | 0x000000f0); __setsr(flags | 0x000000f0);
} }
/* Enable IRQs */ /* Enable IRQs */
static inline void irqenable(void) static inline void up_irq_enable(void)
{ {
uint32_t flags = __getsr(); uint32_t flags = __getsr();
__setsr(flags & ~0x000000f0); __setsr(flags & ~0x000000f0);
@@ -544,11 +544,11 @@ static inline void up_irq_restore(irqstate_t flags)
{ {
if ((flags & 0x000000f0) != 0x000000f0) if ((flags & 0x000000f0) != 0x000000f0)
{ {
irqenable(); up_irq_enable();
} }
else else
{ {
irqdisable(); up_irq_disable();
} }
} }
#endif #endif
+1 -1
View File
@@ -72,7 +72,7 @@ void up_irqinitialize(void)
/* Enable interrupts */ /* Enable interrupts */
#ifndef CONFIG_SUPPRESS_INTERRUPTS #ifndef CONFIG_SUPPRESS_INTERRUPTS
irqenable(); up_irq_enable();
#endif #endif
} }
+7 -7
View File
@@ -222,26 +222,26 @@ static inline irqstate_t irqflags()
* if the X86_FLAGS_IF is set by sti, then interrupts are enable. * if the X86_FLAGS_IF is set by sti, then interrupts are enable.
*/ */
static inline bool irqdisabled(irqstate_t flags) static inline bool up_irq_disabled(irqstate_t flags)
{ {
return ((flags & X86_FLAGS_IF) == 0); return ((flags & X86_FLAGS_IF) == 0);
} }
static inline bool irqenabled(irqstate_t flags) static inline bool up_irq_enabled(irqstate_t flags)
{ {
return ((flags & X86_FLAGS_IF) != 0); return ((flags & X86_FLAGS_IF) != 0);
} }
/* Disable interrupts unconditionally */ /* Disable interrupts unconditionally */
static inline void irqdisable(void) static inline void up_irq_disable(void)
{ {
asm volatile("cli": : :"memory"); asm volatile("cli": : :"memory");
} }
/* Enable interrupts unconditionally */ /* Enable interrupts unconditionally */
static inline void irqenable(void) static inline void up_irq_enable(void)
{ {
asm volatile("sti": : :"memory"); asm volatile("sti": : :"memory");
} }
@@ -251,7 +251,7 @@ static inline void irqenable(void)
static inline irqstate_t up_irq_save(void) static inline irqstate_t up_irq_save(void)
{ {
irqstate_t flags = irqflags(); irqstate_t flags = irqflags();
irqdisable(); up_irq_disable();
return flags; return flags;
} }
@@ -259,9 +259,9 @@ static inline irqstate_t up_irq_save(void)
static inline void up_irq_restore(irqstate_t flags) static inline void up_irq_restore(irqstate_t flags)
{ {
if (irqenabled(flags)) if (up_irq_enabled(flags))
{ {
irqenable(); up_irq_enable();
} }
} }