From: Dan Carpenter <dan.carpenter@oracle.com>
To: kernel-janitors@vger.kernel.org
Subject: [PATCH] RDMA/hns: Fix an error code in hns_roce_create_srq()
Date: Mon, 17 Dec 2018 07:08:15 +0000 [thread overview]
Message-ID: <20181217070815.GF12159@kadam> (raw)
The function accidentally returns success on this error path.
Fixes: c7bcb13442e1 ("RDMA/hns: Add SRQ support for hip08 kernel mode")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
---
drivers/infiniband/hw/hns/hns_roce_srq.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/infiniband/hw/hns/hns_roce_srq.c b/drivers/infiniband/hw/hns/hns_roce_srq.c
index 463df60094e8..6377e734e28e 100644
--- a/drivers/infiniband/hw/hns/hns_roce_srq.c
+++ b/drivers/infiniband/hw/hns/hns_roce_srq.c
@@ -286,6 +286,7 @@ struct ib_srq *hns_roce_create_srq(struct ib_pd *pd,
if (IS_ERR(srq->idx_que.umem)) {
dev_err(hr_dev->dev,
"ib_umem_get error for index queue\n");
+ ret = PTR_ERR(srq->idx_que.umem);
goto err_srq_mtt;
}
--
2.17.1
next reply other threads:[~2018-12-17 7:08 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-17 7:08 Dan Carpenter [this message]
2018-12-17 11:18 ` [PATCH] RDMA/hns: Fix an error code in hns_roce_create_srq() oulijun
2019-06-08 9:27 ` [PATCH] RDMA/hns: Fix an error code in hns_roce_set_user_sq_size() Dan Carpenter
2019-06-12 17:23 ` Leon Romanovsky
2019-06-13 6:05 ` Dan Carpenter
2019-06-13 6:14 ` oulijun
2019-06-13 6:33 ` Leon Romanovsky
2019-06-13 14:05 ` oulijun
2019-06-25 13:22 ` Jason Gunthorpe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20181217070815.GF12159@kadam \
--to=dan.carpenter@oracle.com \
--cc=kernel-janitors@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.