Changeset View
Changeset View
Standalone View
Standalone View
sys/compat/linuxkpi/common/include/linux/kernel.h
Show First 20 Lines • Show All 144 Lines • ▼ Show 20 Lines | #define WARN_ON_ONCE(cond) ({ \ | ||||
} \ | } \ | ||||
unlikely(__ret); \ | unlikely(__ret); \ | ||||
}) | }) | ||||
#define oops_in_progress SCHEDULER_STOPPED() | #define oops_in_progress SCHEDULER_STOPPED() | ||||
#undef ALIGN | #undef ALIGN | ||||
#define ALIGN(x, y) roundup2((x), (y)) | #define ALIGN(x, y) roundup2((x), (y)) | ||||
#define ALIGN_DOWN(x, y) rounddown2(x, y) | |||||
#undef PTR_ALIGN | #undef PTR_ALIGN | ||||
#define PTR_ALIGN(p, a) ((__typeof(p))ALIGN((uintptr_t)(p), (a))) | #define PTR_ALIGN(p, a) ((__typeof(p))ALIGN((uintptr_t)(p), (a))) | ||||
#define IS_ALIGNED(x, a) (((x) & ((__typeof(x))(a) - 1)) == 0) | #define IS_ALIGNED(x, a) (((x) & ((__typeof(x))(a) - 1)) == 0) | ||||
#define DIV_ROUND_UP(x, n) howmany(x, n) | #define DIV_ROUND_UP(x, n) howmany(x, n) | ||||
#define __KERNEL_DIV_ROUND_UP(x, n) howmany(x, n) | #define __KERNEL_DIV_ROUND_UP(x, n) howmany(x, n) | ||||
#define DIV_ROUND_UP_ULL(x, n) DIV_ROUND_UP((unsigned long long)(x), (n)) | #define DIV_ROUND_UP_ULL(x, n) DIV_ROUND_UP((unsigned long long)(x), (n)) | ||||
#define DIV_ROUND_DOWN_ULL(x, n) (((unsigned long long)(x) / (n)) * (n)) | #define DIV_ROUND_DOWN_ULL(x, n) (((unsigned long long)(x) / (n)) * (n)) | ||||
#define FIELD_SIZEOF(t, f) sizeof(((t *)0)->f) | #define FIELD_SIZEOF(t, f) sizeof(((t *)0)->f) | ||||
▲ Show 20 Lines • Show All 602 Lines • Show Last 20 Lines |