39#include "arch/interrupt.h"
56#define OS_INT_ACTIVE IntActive()
66#define OS_INT_INACTIVE (!(OS_INT_ACTIVE))
73#define OS_HWI_PRIO_HIGHEST 0
80#define OS_HWI_PRIO_LOWEST (LOSCFG_HWI_PRIO_LIMIT - 1)
86#if (OS_HWI_PRIO_HIGHEST == 0)
87#define HWI_PRI_VALID(pri) ((pri) <= OS_HWI_PRIO_LOWEST)
89#define HWI_PRI_VALID(pri) (((pri) >= OS_HWI_PRIO_HIGHEST) && ((pri) <= OS_HWI_PRIO_LOWEST))
104#define LOS_ERRNO_HWI_NUM_INVALID LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x00)
105#define OS_ERRNO_HWI_NUM_INVALID LOS_ERRNO_HWI_NUM_INVALID
119#define LOS_ERRNO_HWI_PROC_FUNC_NULL LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x01)
120#define OS_ERRNO_HWI_PROC_FUNC_NULL LOS_ERRNO_HWI_PROC_FUNC_NULL
131#define OS_ERRNO_HWI_CB_UNAVAILABLE LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x02)
145#define LOS_ERRNO_HWI_NO_MEMORY LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x03)
146#define OS_ERRNO_HWI_NO_MEMORY LOS_ERRNO_HWI_NO_MEMORY
161#define LOS_ERRNO_HWI_ALREADY_CREATED LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x04)
162#define OS_ERRNO_HWI_ALREADY_CREATED LOS_ERRNO_HWI_ALREADY_CREATED
176#define LOS_ERRNO_HWI_PRIO_INVALID LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x05)
177#define OS_ERRNO_HWI_PRIO_INVALID LOS_ERRNO_HWI_PRIO_INVALID
188#define OS_ERRNO_HWI_MODE_INVALID LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x06)
199#define OS_ERRNO_HWI_FASTMODE_ALREADY_CREATED LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x07)
213#define LOS_ERRNO_HWI_INTERR LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x08)
214#define OS_ERRNO_HWI_INTERR LOS_ERRNO_HWI_INTERR
229#define LOS_ERRNO_HWI_SHARED_ERROR LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x09)
230#define OS_ERRNO_HWI_SHARED_ERROR LOS_ERRNO_HWI_SHARED_ERROR
241#define OS_ERRNO_HWI_ARG_INVALID LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x0a)
256#define LOS_ERRNO_HWI_HWINUM_UNCREATE LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x0b)
257#define OS_ERRNO_HWI_HWINUM_UNCREATE LOS_ERRNO_HWI_HWINUM_UNCREATE
271#define LOS_ERRNO_HWI_NO_CPUP_MEMORY LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x0c)
285#define LOS_ERRNO_HWI_NOT_INTERRUPT_CONTEXT LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x0d)
299#define LOS_ERRNO_HWI_PTR_NULL LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x0e)
311#define LOS_ERRNO_HWI_ARG_NOT_ENABLED LOS_ERRNO_OS_ERROR(LOS_MOD_HWI, 0x0f)
384#define IRQF_SHARED 0x8000U
415 return ArchIntLock();
436 return ArchIntUnlock();
459 ArchIntRestore(intSave);
756#ifdef LOSCFG_HWI_PRE_POST_PROCESS
797extern VOID LOS_HwiPreHookReg(HWI_PROC_HOOK intPreHook);
818extern VOID LOS_HwiPostHookReg(HWI_PROC_HOOK intPostHook);
#define STATIC
Definition common_def.h:57
#define INLINE
Definition common_def.h:65
UINT16 HWI_PRIOR_T
Definition los_hwi.h:323
UINT32 LOS_HwiClear(HWI_HANDLE_T hwiNum)
clear interrupts.
void(* HWI_PROC_FUNC)(void)
Define the type of a hardware interrupt handling function.
Definition los_hwi.h:356
UINT32 LOS_HwiCreate(HWI_HANDLE_T hwiNum, HWI_PRIOR_T hwiPrio, HWI_MODE_T hwiMode, HWI_PROC_FUNC hwiHandler, HWI_IRQ_PARAM_S *irqParam)
Create a hardware interrupt.
void(* HWI_BOTTOM_HALF_FUNC)(void *)
Define the type of an interrupt bottom half function.
Definition los_hwi.h:376
UINT32 LOS_HwiRespCntGet(HWI_HANDLE_T hwiNum, UINT32 *respCount)
Get the number of interrupt responses.
UINT32 LOS_HwiSendIpi(HWI_HANDLE_T hwiNum, UINT32 cpuMask)
Send inter-core interrupts to designated cores.
UINT32 LOS_HwiDelete(HWI_HANDLE_T hwiNum, HWI_IRQ_PARAM_S *irqParam)
delete a hardware interrupt.
UINT32 LOS_HwiDisable(HWI_HANDLE_T hwiNum)
Disable interrupts.
UINT32 LOS_HwiEnable(HWI_HANDLE_T hwiNum)
Enable interrupts.
UINT32 LOS_HwiSetAffinity(HWI_HANDLE_T hwiNum, UINT32 cpuMask)
Interrupt response specified CPU processing.
UINT32 LOS_HwiSetPriority(HWI_HANDLE_T hwiNum, HWI_PRIOR_T priority)
Set interrupts priority.
struct tagIrqParam HWI_IRQ_PARAM_S
UINT16 HWI_MODE_T
Definition los_hwi.h:329
UINTPTR HWI_ARG_T
Definition los_hwi.h:336
UINT32 HWI_HANDLE_T
Definition los_hwi.h:317
UINT32 LOS_HwiTrigger(HWI_HANDLE_T hwiNum)
Trigger interrupts.
UINT32 LOS_HwiBhworkAdd(HWI_BOTTOM_HALF_FUNC bhHandler, void *data)
create a interrupt bottom half work.
#define LITE_OS_SEC_TEXT
Definition los_builddef.h:50
unsigned short UINT16
Definition los_typedef.h:51
#define VOID
Definition los_typedef.h:88
unsigned int UINTPTR
Definition los_typedef.h:74
unsigned int UINT32
Definition los_typedef.h:52
char CHAR
Definition los_typedef.h:58
int swIrq
Definition los_hwi.h:391
const CHAR * pName
Definition los_hwi.h:393
void * pDevId
Definition los_hwi.h:392
Definition hal_uart_v151_regs_def.h:38