1 /* SPDX-License-Identifier: (GPL-2.0-only or LGPL-2.1-only)
5 * Copyright (C) 2020 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
8 #ifndef _LTTNG_WRAPPER_LIMITS_H
9 #define _LTTNG_WRAPPER_LIMITS_H
11 #include <linux/kernel.h>
14 #define SIZE_MAX (~(size_t)0)
17 #define PHYS_ADDR_MAX (~(phys_addr_t)0)
21 #define U8_MAX ((u8)~0U)
24 #define S8_MAX ((s8)(U8_MAX >> 1))
27 #define S8_MIN ((s8)(-S8_MAX - 1))
30 #define U16_MAX ((u16)~0U)
33 #define S16_MAX ((s16)(U16_MAX >> 1))
36 #define S16_MIN ((s16)(-S16_MAX - 1))
39 #define U32_MAX ((u32)~0U)
42 #define U32_MIN ((u32)0)
45 #define S32_MAX ((s32)(U32_MAX >> 1))
48 #define S32_MIN ((s32)(-S32_MAX - 1))
51 #define U64_MAX ((u64)~0ULL)
54 #define S64_MAX ((s64)(U64_MAX >> 1))
57 #define S64_MIN ((s64)(-S64_MAX - 1))
60 #endif /* _LTTNG_WRAPPER_COMPILER_H */
This page took 0.030518 seconds and 4 git commands to generate.