blob: 29600483ddc594c25c863a0bf30059f0db0b959a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
/* SPDX-License-Identifier: GPL-2.0-only */
#ifndef __MACHINE_ID_H__
#define __MACHINE_ID_H__
#include <linux/types.h>
#include <linux/uuid.h>
#if IS_ENABLED(CONFIG_MACHINE_ID)
const void *machine_id_get_hashable(size_t *len);
void machine_id_set_hashable(const void *hashable, size_t len);
int machine_id_get_app_specific(uuid_t *result, ...) __attribute__((__sentinel__));
#else
static inline const void *machine_id_get_hashable(size_t *len)
{
return NULL;
}
static inline void machine_id_set_hashable(const void *hashable, size_t len)
{
}
static inline int machine_id_get_app_specific(uuid_t *result, ...)
__attribute__((__sentinel__));
static inline int machine_id_get_app_specific(uuid_t *result, ...)
{
return -ENOSYS;
}
#endif /* CONFIG_MACHINE_ID */
#endif /* __MACHINE_ID_H__ */
|