]> CyberLeo.Net >> Repos - FreeBSD/releng/10.0.git/blob - contrib/ofed/libmlx4/fixes/xrc_fix_close_domain.patch
- Copy stable/10 (r259064) to releng/10.0 as part of the
[FreeBSD/releng/10.0.git] / contrib / ofed / libmlx4 / fixes / xrc_fix_close_domain.patch
1 Pass return code to caller in mlx4_close_xrc_domain.
2
3 ibv_cmd_close_xrc_domain() can return a busy or invalid error code.
4 Need to pass this upward to caller.
5 (Bugzilla 999)
6
7 Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il>
8
9 Index: libmlx4/src/verbs.c
10 ===================================================================
11 --- libmlx4.orig/src/verbs.c    2008-09-01 10:51:11.000000000 +0300
12 +++ libmlx4/src/verbs.c 2008-09-01 10:52:40.000000000 +0300
13 @@ -774,9 +774,11 @@
14  
15  int mlx4_close_xrc_domain(struct ibv_xrc_domain *d)
16  {
17 -       ibv_cmd_close_xrc_domain(d);
18 -       free(d);
19 -       return 0;
20 +       int ret;
21 +       ret = ibv_cmd_close_xrc_domain(d);
22 +       if (!ret)
23 +               free(d);
24 +       return ret;
25  }
26  
27  int mlx4_create_xrc_rcv_qp(struct ibv_qp_init_attr *init_attr,