blob: 4a62b14ca419d135ee90b8ca6348bb763d3348a2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
|
move pthread_cond_t fields to the end of structs, because
their size changed from RHAS4 to RHAS5. In all the cases,
the intervening entries were not accessed outside libibverbs
(in non-XRC applications).
The structs modified are: ibv_cq, ibv_srq, and ibv_qp.
(OFED 1.3 libibverbs commit 4c29c266a3c0932cd06e8f2b4e238aecd3c65dcc)
Pointed out by: Changqing Tang <changquing.tang@hp.com>
Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il>
Index: libibverbs/include/infiniband/verbs.h
===================================================================
--- libibverbs.orig/include/infiniband/verbs.h 2009-11-01 15:18:24.585280000 +0200
+++ libibverbs/include/infiniband/verbs.h 2009-11-01 15:18:28.759417000 +0200
@@ -565,13 +565,14 @@ struct ibv_srq {
struct ibv_pd *pd;
uint32_t handle;
- pthread_mutex_t mutex;
- pthread_cond_t cond;
uint32_t events_completed;
uint32_t xrc_srq_num;
struct ibv_xrc_domain *xrc_domain;
struct ibv_cq *xrc_cq;
+
+ pthread_mutex_t mutex;
+ pthread_cond_t cond;
};
struct ibv_qp {
@@ -586,11 +587,12 @@ struct ibv_qp {
enum ibv_qp_state state;
enum ibv_qp_type qp_type;
- pthread_mutex_t mutex;
- pthread_cond_t cond;
uint32_t events_completed;
struct ibv_xrc_domain *xrc_domain;
+
+ pthread_mutex_t mutex;
+ pthread_cond_t cond;
};
struct ibv_comp_channel {
@@ -606,10 +608,11 @@ struct ibv_cq {
uint32_t handle;
int cqe;
- pthread_mutex_t mutex;
- pthread_cond_t cond;
uint32_t comp_events_completed;
uint32_t async_events_completed;
+
+ pthread_mutex_t mutex;
+ pthread_cond_t cond;
};
struct ibv_ah {
|