Cleanup: Move instrumentation/ headers to include/instrumentation/
[lttng-modules.git] / wrapper / uuid.h
CommitLineData
a7008254
MD
1/* SPDX-License-Identifier: (GPL-2.0-only or LGPL-2.1-only)
2 *
3 * wrapper/uuid.h
4 *
5 * Copyright (C) 2020 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
6 */
7
8#ifndef _LTTNG_WRAPPER_UUID_H
9#define _LTTNG_WRAPPER_UUID_H
10
11#include <linux/version.h>
12#include <linux/uuid.h>
13
14#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5,7,0))
15static inline
16void lttng_guid_gen(guid_t *u)
17{
18 return guid_gen(u);
19}
20#else /* #if (LINUX_VERSION_CODE >= KERNEL_VERSION(5,7,0)) */
6a009f4d
MJ
21
22typedef uuid_le guid_t;
23
a7008254
MD
24static inline
25void lttng_guid_gen(guid_t *u)
26{
27 return uuid_le_gen(u);
28}
29#endif /* #else #if (LINUX_VERSION_CODE >= KERNEL_VERSION(5,7,0)) */
30
31#endif /* _LTTNG_WRAPPER_UUID_H */
This page took 0.024447 seconds and 4 git commands to generate.