From: Jason Gunthorpe <jgg@ziepe.ca>
To: Colin King <colin.king@canonical.com>
Cc: Doug Ledford <dledford@redhat.com>,
Leon Romanovsky <leon@kernel.org>,
Parav Pandit <parav@mellanox.com>,
linux-rdma@vger.kernel.org, kernel-janitors@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH][next] RDMA: check for null return from call to ib_get_client_data
Date: Thu, 20 Jun 2019 15:02:17 +0000 [thread overview]
Message-ID: <20190620150217.GA19891@ziepe.ca> (raw)
In-Reply-To: <20190620135052.27367-1-colin.king@canonical.com>
On Thu, Jun 20, 2019 at 02:50:52PM +0100, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> The return from ib_get_client_data can potentially be null, so add a null
> check on umad_dev and return -ENODEV in this unlikely case to avoid any
> null pointer deferences.
It would be a kernel bug if NULL is seen here.
Jason
WARNING: multiple messages have this Message-ID (diff)
From: Jason Gunthorpe <jgg@ziepe.ca>
To: Colin King <colin.king@canonical.com>
Cc: Doug Ledford <dledford@redhat.com>,
Leon Romanovsky <leon@kernel.org>,
Parav Pandit <parav@mellanox.com>,
linux-rdma@vger.kernel.org, kernel-janitors@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH][next] RDMA: check for null return from call to ib_get_client_data
Date: Thu, 20 Jun 2019 12:02:17 -0300 [thread overview]
Message-ID: <20190620150217.GA19891@ziepe.ca> (raw)
In-Reply-To: <20190620135052.27367-1-colin.king@canonical.com>
On Thu, Jun 20, 2019 at 02:50:52PM +0100, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> The return from ib_get_client_data can potentially be null, so add a null
> check on umad_dev and return -ENODEV in this unlikely case to avoid any
> null pointer deferences.
It would be a kernel bug if NULL is seen here.
Jason
next prev parent reply other threads:[~2019-06-20 15:02 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-20 13:50 [PATCH][next] RDMA: check for null return from call to ib_get_client_data Colin King
2019-06-20 13:50 ` Colin King
2019-06-20 15:02 ` Jason Gunthorpe [this message]
2019-06-20 15:02 ` 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=20190620150217.GA19891@ziepe.ca \
--to=jgg@ziepe.ca \
--cc=colin.king@canonical.com \
--cc=dledford@redhat.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=leon@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=parav@mellanox.com \
/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.