Zephyr API Documentation  2.7.0-rc2
A Scalable Open Source RTOS
Architecture-specific IRQ APIs

Functions

static bool arch_is_in_isr (void)
 
static unsigned int arch_irq_lock (void)
 
static void arch_irq_unlock (unsigned int key)
 
static bool arch_irq_unlocked (unsigned int key)
 
void arch_irq_disable (unsigned int irq)
 
void arch_irq_enable (unsigned int irq)
 
int arch_irq_is_enabled (unsigned int irq)
 
int arch_irq_connect_dynamic (unsigned int irq, unsigned int priority, void(*routine)(const void *parameter), const void *parameter, uint32_t flags)
 

Detailed Description

Function Documentation

◆ arch_irq_connect_dynamic()

int arch_irq_connect_dynamic ( unsigned int  irq,
unsigned int  priority,
void(*)(const void *parameter)  routine,
const void parameter,
uint32_t  flags 
)

#include <include/sys/arch_interface.h>

Arch-specific hook to install a dynamic interrupt.

Parameters
irqIRQ line number
priorityInterrupt priority
routineInterrupt service routine
parameterISR parameter
flagsArch-specific IRQ configuration flag
Returns
The vector assigned to this interrupt

◆ arch_irq_disable()

void arch_irq_disable ( unsigned int  irq)

#include <include/sys/arch_interface.h>

Disable the specified interrupt line

Note
: The behavior of interrupts that arrive after this call returns and before the corresponding call to arch_irq_enable() is undefined. The hardware is not required to latch and deliver such an interrupt, though on some architectures that may work. Other architectures will simply lose such an interrupt and never deliver it. Many drivers and subsystems are not tolerant of such dropped interrupts and it is the job of the application layer to ensure that behavior remains correct.
See also
irq_disable()

◆ arch_irq_enable()

void arch_irq_enable ( unsigned int  irq)

#include <include/sys/arch_interface.h>

Enable the specified interrupt line

See also
irq_enable()

◆ arch_irq_is_enabled()

int arch_irq_is_enabled ( unsigned int  irq)

#include <include/sys/arch_interface.h>

Test if an interrupt line is enabled

See also
irq_is_enabled()

◆ arch_irq_lock()

static unsigned int arch_irq_lock ( void  )
inlinestatic

#include <include/sys/arch_interface.h>

Lock interrupts on the current CPU

See also
irq_lock()

◆ arch_irq_unlock()

static void arch_irq_unlock ( unsigned int  key)
inlinestatic

#include <include/sys/arch_interface.h>

Unlock interrupts on the current CPU

See also
irq_unlock()

◆ arch_irq_unlocked()

static bool arch_irq_unlocked ( unsigned int  key)
inlinestatic

#include <include/sys/arch_interface.h>

Test if calling arch_irq_unlock() with this key would unlock irqs

Parameters
keyvalue returned by arch_irq_lock()
Returns
true if interrupts were unlocked prior to the arch_irq_lock() call that produced the key argument.

◆ arch_is_in_isr()

static bool arch_is_in_isr ( void  )
inlinestatic

#include <kernel/include/kernel_arch_interface.h>

Test if the current context is in interrupt context

XXX: This is inconsistently handled among arches wrt exception context See: #17656

Returns
true if we are in interrupt context