projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8cc0698
)
IB/mlx4: Remove unneeded NULL check
author
Yuval Shaia
<yuval.shaia@oracle.com>
Tue, 11 Dec 2018 10:26:35 +0000
(12:26 +0200)
committer
Jason Gunthorpe
<jgg@mellanox.com>
Tue, 11 Dec 2018 21:38:18 +0000
(14:38 -0700)
NULL check for kfree is unnecessary, remove it.
Fixes:
b42dde478bca
("IB/mlx4: Rework special QP creation error path")
Signed-off-by: Yuval Shaia <yuval.shaia@oracle.com>
Reviewed-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/hw/mlx4/qp.c
patch
|
blob
|
history
diff --git
a/drivers/infiniband/hw/mlx4/qp.c
b/drivers/infiniband/hw/mlx4/qp.c
index
0711ca1
..
74ef7a0
100644
(file)
--- a/
drivers/infiniband/hw/mlx4/qp.c
+++ b/
drivers/infiniband/hw/mlx4/qp.c
@@
-1211,10
+1211,10
@@
err_db:
mlx4_db_free(dev->dev, &qp->db);
err:
- if (sqp)
- kfree(sqp);
- else if (!*caller_qp)
+ if (!sqp && !*caller_qp)
kfree(qp);
+ kfree(sqp);
+
return err;
}