]>
Commit | Line | Data |
---|---|---|
9f95a23c TL |
1 | /* |
2 | * Copyright(c) 2012-2018 Intel Corporation | |
3 | * SPDX-License-Identifier: BSD-3-Clause-Clear | |
4 | */ | |
5 | ||
6 | #ifndef __METADATA_HASH_H__ | |
7 | #define __METADATA_HASH_H__ | |
8 | ||
9 | /** | |
10 | * @file metadata_.h | |
11 | * @brief Metadata Service - Hash Implementation | |
12 | */ | |
13 | ||
14 | #include "../ocf_request.h" | |
15 | /** | |
16 | * @brief Metada hash elements type | |
17 | */ | |
18 | enum ocf_metadata_segment { | |
19 | metadata_segment_sb_config = 0, /*!< Super block conf */ | |
20 | metadata_segment_sb_runtime, /*!< Super block runtime */ | |
21 | metadata_segment_reserved, /*!< Reserved space on disk */ | |
f67539c2 TL |
22 | metadata_segment_part_config, /*!< Part Config Metadata */ |
23 | metadata_segment_part_runtime, /*!< Part Runtime Metadata */ | |
9f95a23c TL |
24 | metadata_segment_core_config, /*!< Core Config Metadata */ |
25 | metadata_segment_core_runtime, /*!< Core Runtime Metadata */ | |
26 | metadata_segment_core_uuid, /*!< Core UUID */ | |
27 | /* .... new fixed size sections go here */ | |
28 | ||
29 | metadata_segment_fixed_size_max, | |
30 | metadata_segment_variable_size_start = metadata_segment_fixed_size_max, | |
31 | ||
32 | /* sections with size dependent on cache device size go here: */ | |
33 | metadata_segment_cleaning = /*!< Cleaning policy */ | |
34 | metadata_segment_variable_size_start, | |
35 | metadata_segment_eviction, /*!< Eviction policy */ | |
36 | metadata_segment_collision, /*!< Collision */ | |
37 | metadata_segment_list_info, /*!< Collision */ | |
38 | metadata_segment_hash, /*!< Hash */ | |
39 | /* .... new variable size sections go here */ | |
40 | ||
41 | metadata_segment_max, /*!< MAX */ | |
42 | }; | |
43 | ||
44 | /** | |
45 | * @brief Get metadata interface implementation | |
46 | * | |
47 | * @return metadata interface | |
48 | */ | |
49 | const struct ocf_metadata_iface *metadata_hash_get_iface(void); | |
50 | ||
51 | #endif /* METADATA_HASH_H_ */ |