Motr  M0
node_helper.h
Go to the documentation of this file.
1 /* -*- C -*- */
2 /*
3  * Copyright (c) 2012-2020 Seagate Technology LLC and/or its Affiliates
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  * For any questions about this software or licensing,
18  * please email opensource@seagate.com or cortx-questions@seagate.com.
19  *
20  */
21 
22 
23 #pragma once
24 
25 #ifndef __MOTR_NET_TEST_NODE_HELPER_H__
26 #define __MOTR_NET_TEST_NODE_HELPER_H__
27 
28 #include "net/test/commands.h" /* m0_net_test_role */
29 
46 };
47 
52 };
53 
59 };
60 
96 };
97 
99 void m0_net_test_nh_init(struct m0_net_test_nh *nh,
100  const struct m0_net_test_cmd_init *icmd);
104 void m0_net_test_nh_fini(struct m0_net_test_nh *nh);
105 
117  struct m0_net_test_cmd_status_data *sd);
118 
124  enum m0_net_test_nh_msg_status status,
125  enum m0_net_test_nh_msg_direction direction);
134 
137  const struct m0_net_test_cmd *cmd,
138  struct m0_net_test_cmd *reply);
139 
144 #endif /* __MOTR_NET_TEST_NODE_HELPER_H__ */
145 
146 /*
147  * Local variables:
148  * c-indentation-style: "K&R"
149  * c-basic-offset: 8
150  * tab-width: 8
151  * fill-column: 79
152  * scroll-step: 1
153  * End:
154  */
m0_net_test_type
Definition: commands.h:68
m0_net_test_nh_msg_type
Definition: node_helper.h:48
uint64_t m0_time_t
Definition: time.h:37
enum m0_net_test_role ntnh_role
Definition: node_helper.h:64
uint64_t ntnh_transfers_max_nr
Definition: node_helper.h:93
enum m0_net_test_type ntnh_type
Definition: node_helper.h:66
struct m0_net_test_cmd_status_data ntnh_sd_copy
Definition: node_helper.h:84
m0_net_test_nh_msg_status
Definition: node_helper.h:42
m0_net_test_nh_msg_direction
Definition: node_helper.h:55
void m0_net_test_nh_init(struct m0_net_test_nh *nh, const struct m0_net_test_cmd_init *icmd)
Definition: node_helper.c:34
void m0_net_test_nh_cmd_status(struct m0_net_test_nh *nh, const struct m0_net_test_cmd *cmd, struct m0_net_test_cmd *reply)
Definition: node_helper.c:146
void m0_net_test_nh_sd_update(struct m0_net_test_nh *nh, enum m0_net_test_nh_msg_type type, enum m0_net_test_nh_msg_status status, enum m0_net_test_nh_msg_direction direction)
Definition: node_helper.c:83
void m0_net_test_nh_sd_get_locked(struct m0_net_test_nh *nh, struct m0_net_test_cmd_status_data *sd)
Definition: node_helper.c:72
struct m0_mutex ntnh_sd_copy_lock
Definition: node_helper.h:86
void m0_net_test_nh_fini(struct m0_net_test_nh *nh)
Definition: node_helper.c:56
m0_net_test_role
Definition: commands.h:59
void m0_net_test_nh_sd_update_rtt(struct m0_net_test_nh *nh, m0_time_t rtt)
Definition: node_helper.c:129
bool ntnh_test_initialized
Definition: node_helper.h:88
bool m0_net_test_nh_transfer_next(struct m0_net_test_nh *nh)
Definition: node_helper.c:136
void m0_net_test_nh_sd_copy_locked(struct m0_net_test_nh *nh)
Definition: node_helper.c:63
struct m0_net_test_cmd_status_data ntnh_sd
Definition: node_helper.h:82
int type
Definition: dir.c:1031
bool m0_net_test_nh__invariant(struct m0_net_test_nh *nh)
Definition: node_helper.c:51
static struct m0_dtm_oper_descr reply
Definition: transmit.c:94
Definition: mutex.h:47
uint64_t ntnh_transfers_started_nr
Definition: node_helper.h:95