From: Leon Romanovsky <leon@kernel.org>
To: Jia-Ju Bai <baijiaju1990@gmail.com>
Cc: bharat@chelsio.com, dledford@redhat.com, jgg@ziepe.ca,
linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] infiniband: hw: cxgb4: fix error return code of close_listsrv_rpl()
Date: Sun, 7 Mar 2021 11:13:22 +0200 [thread overview]
Message-ID: <YESZMn77CV7DJTUw@unreal> (raw)
In-Reply-To: <20210306135548.17939-1-baijiaju1990@gmail.com>
On Sat, Mar 06, 2021 at 05:55:48AM -0800, Jia-Ju Bai wrote:
> When ep is NULL, no error code of close_listsrv_rpl() is returned.
> To fix this bug, close_listsrv_rpl() returns -EINVAL in this case.
I don't think that this is an error.
>
> Reported-by: TOTE Robot <oslab@tsinghua.edu.cn>
> Signed-off-by: Jia-Ju Bai <baijiaju1990@gmail.com>
> ---
> drivers/infiniband/hw/cxgb4/cm.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/infiniband/hw/cxgb4/cm.c b/drivers/infiniband/hw/cxgb4/cm.c
> index 8769e7aa097f..94492d2dfdc7 100644
> --- a/drivers/infiniband/hw/cxgb4/cm.c
> +++ b/drivers/infiniband/hw/cxgb4/cm.c
> @@ -2400,7 +2400,7 @@ static int close_listsrv_rpl(struct c4iw_dev *dev, struct sk_buff *skb)
>
> if (!ep) {
> pr_warn("%s stid %d lookup failure!\n", __func__, stid);
> - goto out;
> + return -EINVAL;
> }
> pr_debug("ep %p\n", ep);
> c4iw_wake_up_noref(ep->com.wr_waitp, status2errno(rpl->status));
> --
> 2.17.1
>
prev parent reply other threads:[~2021-03-07 9:14 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-06 13:55 [PATCH] infiniband: hw: cxgb4: fix error return code of close_listsrv_rpl() Jia-Ju Bai
2021-03-07 9:13 ` Leon Romanovsky [this message]
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=YESZMn77CV7DJTUw@unreal \
--to=leon@kernel.org \
--cc=baijiaju1990@gmail.com \
--cc=bharat@chelsio.com \
--cc=dledford@redhat.com \
--cc=jgg@ziepe.ca \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@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.