当前仅显示指定条件回帖 [ 展开查看全部 ]
文件名称:
osal_spinlock-h.md
所在目录:
Openharmony v1.0 / docs / api / api-SmartVision-Devices
文件大小:
8.48 KB
下载地址:
文本预览:
# osal\_spinlock.h
## **Overview**
**Related Modules:**
[OSAL](OSAL.md)
**Description:**
Declares spinlock types and interfaces.
This file provides the interfaces for initializing, destroying, obtaining, and releasing a spinlock, the interfaces for obtaining a spinlock and disabling the interrupt request \(IRQ\), releasing a spinlock and enabling the IRQ, obtaining a spinlock, disabling the IRQ, and saving its status, and releasing a spinlock, enabling the IRQ, and restoring the saved IRQ status. The spinlock needs to be destroyed when it is no longer used.
**Since:**
1.0
**Version:**
1.0
## **Summary**
## Data Structures
## Macros
## Functions
## **Overview**
**Related Modules:**
[OSAL](OSAL.md)
**Description:**
Declares spinlock types and interfaces.
This file provides the interfaces for initializing, destroying, obtaining, and releasing a spinlock, the interfaces for obtaining a spinlock and disabling the interrupt request \(IRQ\), releasing a spinlock and enabling the IRQ, obtaining a spinlock, disabling the IRQ, and saving its status, and releasing a spinlock, enabling the IRQ, and restoring the saved IRQ status. The spinlock needs to be destroyed when it is no longer used.
**Since:**
1.0
**Version:**
1.0
## **Summary**
## Data Structures
## Macros
OSAL_DECLARE_SPINLOCK(spinlock) OsalSpinlock spinlock |
## Functions
OsalSpinInit (OsalSpinlock *spinlock) | |
OsalSpinDestroy (OsalSpinlock *spinlock) | |
OsalSpinLock (OsalSpinlock *spinlock) | |
OsalSpinUnlock (OsalSpinlock *spinlock) | |
OsalSpinLockIrq (OsalSpinlock *spinlock) | Obtains a spinlock and disables the IRQ. |
OsalSpinUnlockIrq (OsalSpinlock *spinlock) | Releases a spinlock and enables the IRQ. |
OsalSpinLockIrqSave (OsalSpinlock *spinlock, uint32_t *flags) | Obtains a spinlock, disables the IRQ, and saves its status. |
OsalSpinUnlockIrqRestore (OsalSpinlock *spinlock, uint32_t *flags) | Releases a spinlock, enables the IRQ, and restores the saved IRQ status. |
点赞
回复
X