CDI SDK
SDK for transporting chunks of data reliably and with low latency using a polled mode network driver.
Loading...
Searching...
No Matches
src
cdi
configuration.h
Go to the documentation of this file.
1
// -------------------------------------------------------------------------------------------
2
// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.
3
// This file is part of the AWS CDI-SDK, licensed under the BSD 2-Clause "Simplified" License.
4
// License details at: https://github.com/aws/aws-cdi-sdk/blob/mainline/LICENSE
5
// -------------------------------------------------------------------------------------------
6
13
#ifndef CDI_CONFIGURATION_H__
14
#define CDI_CONFIGURATION_H__
15
16
//*********************************************************************************************************************
17
//***************************************** IMPLEMENTATION VARIANTS AND OPTION ****************************************
18
//*********************************************************************************************************************
19
20
//*********************************************************************************************************************
21
//********************************************* FEATURES TO AID DEBUGGING *********************************************
22
//*********************************************************************************************************************
23
25
//#define DEBUG_PACKET_SEQUENCES
26
28
//#define DEBUG_POLL_THREAD_SLEEP_TIME
29
31
//#define DEBUG_TX_PACKET_SGL_ENTRY_POOL_FREE_COUNT
32
35
//#define DEBUG_ENABLE_QUEUE_DEBUGGING
36
39
//#define DEBUG_ENABLE_POOL_DEBUGGING_EFA_PROBE
40
42
//#define DEBUG_RX_REORDER_ALL
43
//#define DEBUG_RX_REORDER_MIN
44
//#define DEBUG_RX_REORDER_ERROR
45
47
//#define DEBUG_T_DIGEST_UNIT_TEST
48
//#define DEBUG_T_DIGEST_LOGGING
49
//#define DEBUG_T_DIGEST_ARRAYS
50
52
//#define DEBUG_TX_PACKET_SGL_ENTRIES
53
55
//#define DEBUG_RX_DUMP_RAW_SGL_ENTRIES
56
58
//#define DEBUG_RX_PAYLOAD_SGL_ENTRY_FREE_COUNT
59
62
//#define DISABLE_PROBE_MONITORING
63
65
//#define LIBFABRIC_LOG_LEVEL (0) // 0=FI_LOG_WARN, 3=FI_LOG_DEBUG
66
67
//*********************************************************************************************************************
68
//******************************************* MAX SIZES FOR STATIC DATA/ARRAYS ****************************************
69
//*********************************************************************************************************************
70
72
#define HD_TO_4K_FACTOR (4)
73
74
#define NO_GROW_COUNT (0)
75
#define NO_GROW_SIZE (0)
76
78
#define MAX_RX_OUT_OF_ORDER (128)
80
#define MAX_RX_OUT_OF_ORDER_GROW (8)
81
83
#define MAX_ERROR_STRING_LENGTH (1024)
84
86
#define MAX_IP_STRING_LENGTH (64)
87
89
#define MAX_IPV6_GID_LENGTH (32)
90
92
#define MAX_IPV6_ADDRESS_STRING_LENGTH (64)
93
95
#define MAX_POOL_NAME_LENGTH (64)
96
98
#define MAX_FIFO_NAME_LENGTH (64)
99
101
#define MAX_PAYLOADS_PER_CONNECTION (100)
102
104
#define MAX_TX_PACKET_WORK_REQUESTS_PER_CONNECTION (3000*HD_TO_4K_FACTOR)
105
109
#define TX_AVM_PACKET_HEADER_POOL_SIZE_PER_CONNECTION (100)
110
112
#define TX_PACKET_SGL_ENTRY_SIZE_PER_CONNECTION (3000*HD_TO_4K_FACTOR)
114
#define TX_PACKET_SGL_ENTRY_SIZE_PER_CONNECTION_GROW (500)
115
118
#define MAX_TX_PACKETS_PER_CONNECTION (3000*HD_TO_4K_FACTOR)
120
#define TX_PACKET_POOL_SIZE_GROW (100)
121
124
#define MAX_TX_PACKET_BATCHES_PER_CONNECTION (12*HD_TO_4K_FACTOR)
126
#define TX_PACKET_SEND_QUEUE_SIZE_GROW (10)
127
129
#define MAX_TX_SGL_PACKET_ENTRIES (4)
130
133
#define SIMULTANEOUS_TX_PACKET_LIMIT (50)
134
136
#define MAX_TX_BULK_COMPLETION_QUEUE_MESSAGES (SIMULTANEOUS_TX_PACKET_LIMIT)
137
139
#define MAX_RX_BULK_COMPLETION_QUEUE_MESSAGES (50)
140
142
#define MAX_RX_PACKETS_PER_CONNECTION (10000)
144
#define MAX_RX_PACKETS_PER_CONNECTION_GROW (500)
145
147
#define RX_SOCKET_BUFFER_SIZE (1000)
149
#define RX_SOCKET_BUFFER_SIZE_GROW (100)
150
152
#define MAX_ENDPOINT_COMMAND_QUEUE_SIZE (10)
153
155
#define MAX_POOL_GROW_COUNT (5)
156
158
#define MAX_QUEUE_GROW_COUNT (5)
159
163
#define MAX_MSG_PREFIX_SIZE (22 * 8)
164
165
//*********************************************************************************************************************
166
//********************************************* SETTINGS FOR EFA ADAPTER **********************************************
167
//*********************************************************************************************************************
168
170
#define EFA_TX_PACKET_CACHE_SIZE (16)
171
173
#define EFA_RX_PACKET_BUFFER_CACHE_SIZE (16)
174
176
#define EFA_CQ_READ_SIZE (50)
177
178
//*********************************************************************************************************************
179
//********************************************** SETTINGS FOR EFA PROBE ***********************************************
180
//*********************************************************************************************************************
181
183
#define PROBE_RX_PACKET_BUFFERS_PER_CONNECTION (100)
184
186
#define MAX_PROBE_CONTROL_COMMANDS_PER_CONNECTION (20)
187
189
#define CONTROL_INTERFACE_TX_BUFFER_SIZE_BYTES (4096)
190
193
#define RX_RESET_COMMAND_MAX_RETRIES (3)
194
197
#define SEND_RESET_COMMAND_FREQUENCY_MSEC (2000)
198
200
#define ENDPOINT_MANAGER_COMPLETION_TIMEOUT_MSEC (1000)
201
204
#define TX_CONNECTION_DELAY_MSEC (1000)
205
208
#define SEND_PING_COMMAND_FREQUENCY_MSEC (5000)
209
212
#define TX_COMMAND_MAX_RETRIES (40)
213
218
#define TX_COMMAND_ACK_TIMEOUT_MSEC (500)
219
223
#define RX_PING_MONITOR_TIMEOUT_MSEC (5000 + (SEND_PING_COMMAND_FREQUENCY_MSEC*3))
224
229
#define EFA_PROBE_PACKET_BUFFER_COUNT (CDI_MAX_SIMULTANEOUS_CONNECTIONS*CDI_MAX_ENDPOINTS_PER_CONNECTION)
230
232
#define EFA_PROBE_PACKET_DATA_SIZE (1024)
233
236
#define EFA_PROBE_PACKET_COUNT (1000)
237
240
#define EFA_TX_PROBE_ACK_TIMEOUT (100)
241
243
#define EFA_TX_PROBE_ACK_MAX_RETRIES (5)
244
247
#define EFA_PROBE_MONITOR_TIMEOUT_MSEC (3000)
248
250
#define EFA_PROBE_PACKET_DATA_PATTERN (0x41)
251
253
#define DEFAULT_TIMEOUT_MSEC (1000)
254
258
#define RX_LINEAR_BUFFER_COUNT (5)
259
260
//*********************************************************************************************************************
261
//****************************************** SETTINGS FOR SYSTEM MONITORING *******************************************
262
//*********************************************************************************************************************
263
265
#define SYSTEM_MONITORING_SLEEP_TIME_MS (400)
266
268
#define SYSTEM_MONITORING_SLEEP_TIME_TOLERANCE_MS (SYSTEM_MONITORING_SLEEP_TIME_MS + 200)
269
270
//*********************************************************************************************************************
271
//********************************************* SETTINGS FOR CLOUDWATCH ***********************************************
272
//*********************************************************************************************************************
273
#ifndef CDI_NO_MONITORING
276
#define CLOUDWATCH_METRICS_ENABLED
277
279
#define CLOUDWATCH_DEFAULT_NAMESPACE_STRING ("CloudDigitalInterface")
280
283
#define MAX_CLOUDWATCH_STRING_LENGTH (256)
284
286
#define CLOUDWATCH_STATS_FIFO_DEPTH (1000)
287
288
//*********************************************************************************************************************
289
//***************************************** SETTINGS FOR METRICS GATHERING ********************************************
290
//*********************************************************************************************************************
291
293
#define METRICS_GATHERING_SERVICE_ENABLED
294
#endif
// CDI_NO_MONITORING
295
296
#endif
// CDI_CONFIGURATION_H__
Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.