24 #ifndef __MOTR_POOL_MACHINE_H__ 25 #define __MOTR_POOL_MACHINE_H__ 28 #include "format/format_xc.h" 30 #include "lib/tlist_xc.h" 229 uint32_t max_node_failures,
230 uint32_t max_device_failures);
275 uint32_t device_index,
295 uint32_t device_index,
305 uint32_t device_index);
314 uint32_t device_index,
315 uint32_t *spare_slot_out);
337 uint32_t device_index,
338 uint32_t *spare_slot_out);
360 struct m0_fid *cob_fid_out);
struct m0_poolmach_state * pm_state
M0_TL_DESCR_DECLARE(poolmach_events, M0_EXTERN)
struct m0_tl pst_event_queue
M0_INTERNAL bool m0_poolmach_sns_repair_spare_contains_data(struct m0_poolmach *p, uint32_t spare_slot, bool check_state)
M0_INTERNAL int m0_poolmach_state_transit(struct m0_poolmach *pm, const struct m0_poolmach_event *event)
struct m0_be_clink pst_conf_ready
struct m0_pool_version * pm_pver
M0_INTERNAL void m0_poolmach_event_dump(const struct m0_poolmach_event *e)
M0_INTERNAL int m0_poolmach_init_by_conf(struct m0_poolmach *pm, struct m0_conf_pver *pver)
M0_INTERNAL void m0_poolmach_device_state_dump(struct m0_poolmach *pm)
M0_INTERNAL int m0_poolmach_fid_to_idx(struct m0_poolmach *pm, struct m0_fid *fid, uint32_t *idx)
struct m0_poolnode * pst_nodes_array
static struct m0_addb2_mach * mach
M0_INTERNAL int m0_poolmach_device_state(struct m0_poolmach *pm, uint32_t device_index, enum m0_pool_nd_state *state_out)
M0_TL_DECLARE(poolmach_events, M0_INTERNAL, struct m0_poolmach_event_link)
struct m0_pooldev * pst_devices_array
M0_INTERNAL int m0_poolmach_spare_build(struct m0_poolmach *mach, struct m0_pool *pool, enum m0_conf_pver_kind kind)
struct m0_poolmach_event pel_event
M0_INTERNAL void m0_poolmach_event_list_dump_locked(struct m0_poolmach *pm)
struct m0_be_clink pst_conf_exp
M0_INTERNAL void m0_poolmach_event_list_dump(struct m0_poolmach *pm)
M0_INTERNAL void m0_poolmach_failvec_apply(struct m0_poolmach *pm, const struct m0_ha_nvec *nvec)
M0_INTERNAL bool m0_poolmach_device_is_in_spare_usage_array(struct m0_poolmach *pm, uint32_t device_index)
uint32_t pe_type M0_XCA_FENUM(m0_poolmach_event_owner_type)
M0_INTERNAL void m0_poolmach_event_queue_apply(struct m0_poolmach *pm)
M0_INTERNAL int m0_poolmach_device_node_return(struct m0_poolmach *pm, uint32_t device_index, struct m0_poolnode **node_out)
M0_INTERNAL int m0_poolmach_init(struct m0_poolmach *pm, struct m0_pool_version *pver, uint32_t nr_nodes, uint32_t nr_devices, uint32_t nr_spare, uint32_t max_node_failures, uint32_t max_device_failures)
static struct m0_pool pool
M0_INTERNAL uint64_t m0_poolmach_nr_dev_failures(struct m0_poolmach *pm)
uint32_t pst_max_node_failures
M0_INTERNAL int m0_poolmach_sns_repair_spare_query(struct m0_poolmach *pm, uint32_t device_index, uint32_t *spare_slot_out)
enum m0_pool_nd_state M0_XCA_ENUM
uint32_t pst_max_device_failures
M0_INTERNAL void m0_poolmach_fini(struct m0_poolmach *pm)
M0_INTERNAL uint32_t m0_poolmach_equeue_length(struct m0_poolmach *pm)
enum m0_pool_nd_state pe_state
struct m0_tl pst_events_list
struct m0_pool_spare_usage * pst_spare_usage_array
M0_INTERNAL int m0_poolmach_node_state(struct m0_poolmach *pm, uint32_t node_index, enum m0_pool_nd_state *state_out)
M0_INTERNAL int m0_poolmach_sns_rebalance_spare_query(struct m0_poolmach *pm, uint32_t device_index, uint32_t *spare_slot_out)
M0_INTERNAL void m0_poolmach_gob2cob(struct m0_poolmach *pm, const struct m0_fid *gfid, uint32_t idx, struct m0_fid *cob_fid)
m0_poolmach_event_owner_type
struct m0_tlink pel_linkage
M0_INTERNAL void m0_poolmach_state_last_cancel(struct m0_poolmach *pm)