⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 xenspinlock.h

📁 xen虚拟机源代码安装包
💻 H
字号:
#ifndef _ASM_IA64_XENSPINLOCK_H#define _ASM_IA64_XENSPINLOCK_H/* * spin_[un]lock_recursive(): Use these forms when the lock can (safely!) be * reentered recursively on the same CPU. All critical regions that may form * part of a recursively-nested set must be protected by these forms. If there * are any critical regions that cannot form part of such a set, they can use * standard spin_[un]lock(). */#define _raw_spin_lock_recursive(_lock)            \    do {                                           \        int cpu = smp_processor_id();              \        if ( likely((_lock)->recurse_cpu != cpu) ) \        {                                          \            spin_lock(_lock);                      \            (_lock)->recurse_cpu = cpu;            \        }                                          \        (_lock)->recurse_cnt++;                    \    } while ( 0 )#define _raw_spin_unlock_recursive(_lock)          \    do {                                           \        if ( likely(--(_lock)->recurse_cnt == 0) ) \        {                                          \            (_lock)->recurse_cpu = -1;             \            spin_unlock(_lock);                    \        }                                          \    } while ( 0 )#endif /*  _ASM_IA64_XENSPINLOCK_H */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -