From 8dec7c70575785729a6a9e6719a955e9c545bcab Mon Sep 17 00:00:00 2001 From: André Fabian Silva Delgado Date: Fri, 5 Aug 2016 02:19:08 -0300 Subject: Linux-libre 4.6.5-gnu --- drivers/infiniband/sw/rdmavt/qp.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'drivers/infiniband/sw') diff --git a/drivers/infiniband/sw/rdmavt/qp.c b/drivers/infiniband/sw/rdmavt/qp.c index a9e3bcc52..a0ecf08b2 100644 --- a/drivers/infiniband/sw/rdmavt/qp.c +++ b/drivers/infiniband/sw/rdmavt/qp.c @@ -683,8 +683,10 @@ struct ib_qp *rvt_create_qp(struct ib_pd *ibpd, * initialization that is needed. */ priv = rdi->driver_f.qp_priv_alloc(rdi, qp, gfp); - if (!priv) + if (IS_ERR(priv)) { + ret = priv; goto bail_qp; + } qp->priv = priv; qp->timeout_jiffies = usecs_to_jiffies((4096UL * (1UL << qp->timeout)) / -- cgit v1.2.3-54-g00ecf