mirror of
https://github.com/openvswitch/ovs
synced 2025-09-07 17:55:20 +00:00
20 lines
403 B
C
20 lines
403 B
C
![]() |
#ifndef __ASM_GENERIC_BUG_WRAPPER_H
|
||
|
#define __ASM_GENERIC_BUG_WRAPPER_H
|
||
|
|
||
|
#include_next <asm-generic/bug.h>
|
||
|
|
||
|
#ifndef WARN_ON_ONCE
|
||
|
#define WARN_ON_ONCE(condition) ({ \
|
||
|
static int __warned; \
|
||
|
int __ret_warn_once = !!(condition); \
|
||
|
\
|
||
|
if (unlikely(__ret_warn_once) && !__warned) { \
|
||
|
WARN_ON(1); \
|
||
|
__warned = 1; \
|
||
|
} \
|
||
|
unlikely(__ret_warn_once); \
|
||
|
})
|
||
|
#endif
|
||
|
|
||
|
#endif
|