]> git.proxmox.com Git - ceph.git/blob - ceph/src/pmdk/src/libpmempool/pmempool.h
710f2353ce5647a0a9cb031cddcd97b7e4e4528f
[ceph.git] / ceph / src / pmdk / src / libpmempool / pmempool.h
1 /* SPDX-License-Identifier: BSD-3-Clause */
2 /* Copyright 2016-2020, Intel Corporation */
3
4 /*
5 * pmempool.h -- internal definitions for libpmempool
6 */
7
8 #ifndef PMEMPOOL_H
9 #define PMEMPOOL_H
10
11 #ifdef __cplusplus
12 extern "C" {
13 #endif
14
15 #define PMEMPOOL_LOG_PREFIX "libpmempool"
16 #define PMEMPOOL_LOG_LEVEL_VAR "PMEMPOOL_LOG_LEVEL"
17 #define PMEMPOOL_LOG_FILE_VAR "PMEMPOOL_LOG_FILE"
18
19 enum check_result {
20 CHECK_RESULT_CONSISTENT,
21 CHECK_RESULT_NOT_CONSISTENT,
22 CHECK_RESULT_ASK_QUESTIONS,
23 CHECK_RESULT_PROCESS_ANSWERS,
24 CHECK_RESULT_REPAIRED,
25 CHECK_RESULT_CANNOT_REPAIR,
26 CHECK_RESULT_ERROR,
27 CHECK_RESULT_INTERNAL_ERROR
28 };
29
30 /*
31 * pmempool_check_ctx -- context and arguments for check command
32 */
33 struct pmempool_check_ctx {
34 struct pmempool_check_args args;
35 char *path;
36 char *backup_path;
37
38 struct check_data *data;
39 struct pool_data *pool;
40 enum check_result result;
41 unsigned sync_required;
42 };
43
44 #ifdef __cplusplus
45 }
46 #endif
47
48 #endif