Motr  M0
parity_repair.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2013-2020 Seagate Technology LLC and/or its Affiliates
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  * For any questions about this software or licensing,
17  * please email opensource@seagate.com or cortx-questions@seagate.com.
18  *
19  */
20 
21 
22 #pragma once
23 
24 #ifndef __MOTR_SNS_PARITY_REPAIR_H__
25 #define __MOTR_SNS_PARITY_REPAIR_H__
26 
27 #include "layout/pdclust.h"
28 #include "fid/fid.h"
29 #include "pool/pool.h"
30 
42 M0_INTERNAL int m0_sns_repair_spare_map(struct m0_poolmach *pm,
43  const struct m0_fid *fid,
44  struct m0_pdclust_layout *pl,
45  struct m0_pdclust_instance *pi,
46  uint64_t group_number,
47  uint64_t unit_number,
48  uint32_t *spare_slot_out,
49  uint32_t *spare_slot_out_prev);
50 
51 M0_INTERNAL int m0_sns_repair_spare_rebalancing(struct m0_poolmach *pm,
52  const struct m0_fid *fid,
53  struct m0_pdclust_layout *pl,
54  struct m0_pdclust_instance *pi,
55  uint64_t group, uint64_t unit,
56  uint32_t *spare_slot_out,
57  uint32_t *spare_slot_out_prev);
67 M0_INTERNAL int m0_sns_repair_data_map(struct m0_poolmach *pm,
68  struct m0_pdclust_layout *pl,
69  struct m0_pdclust_instance *pi,
70  uint64_t group_number,
71  uint64_t spare_unit_number,
72  uint64_t *data_unit_id_out);
73 
74 #endif /* __MOTR_SNS_PARITY_REPAIR_H__ */
75 
76 /*
77  * Local variables:
78  * c-indentation-style: "K&R"
79  * c-basic-offset: 8
80  * tab-width: 8
81  * fill-column: 80
82  * scroll-step: 1
83  * End:
84  */
struct m0_fid fid
Definition: di.c:46
M0_INTERNAL int m0_sns_repair_spare_rebalancing(struct m0_poolmach *pm, const struct m0_fid *fid, struct m0_pdclust_layout *pl, struct m0_pdclust_instance *pi, uint64_t group, uint64_t unit, uint32_t *spare_slot_out, uint32_t *spare_slot_out_prev)
M0_INTERNAL int m0_sns_repair_data_map(struct m0_poolmach *pm, struct m0_pdclust_layout *pl, struct m0_pdclust_instance *pi, uint64_t group_number, uint64_t spare_unit_number, uint64_t *data_unit_id_out)
struct m0_pdclust_instance pi
Definition: fd.c:107
static void group(void)
Definition: sm.c:386
Definition: fid.h:38
M0_INTERNAL int m0_sns_repair_spare_map(struct m0_poolmach *pm, const struct m0_fid *fid, struct m0_pdclust_layout *pl, struct m0_pdclust_instance *pi, uint64_t group_number, uint64_t unit_number, uint32_t *spare_slot_out, uint32_t *spare_slot_out_prev)