From: Ido Schimmel <idosch@idosch.org>
To: Colin King <colin.king@canonical.com>
Cc: Jiri Pirko <jiri@nvidia.com>, Ido Schimmel <idosch@nvidia.com>,
"David S . Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
Mykola Kostenok <c_mykolak@nvidia.com>,
Vadim Pasternak <vadimp@nvidia.com>,
netdev@vger.kernel.org, kernel-janitors@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH][next] mlxsw: thermal: Fix null dereference of NULL temperature parameter
Date: Wed, 9 Jun 2021 21:07:35 +0300 [thread overview]
Message-ID: <YMEDZ4/7atRSTcOL@shredder> (raw)
In-Reply-To: <20210609175657.299112-1-colin.king@canonical.com>
On Wed, Jun 09, 2021 at 06:56:57PM +0100, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> The call to mlxsw_thermal_module_temp_and_thresholds_get passes a NULL
> pointer for the temperature and this can be dereferenced in this function
> if the mlxsw_reg_query call fails. The simplist fix is to pass the
> address of dummy temperature variable instead of a NULL pointer.
>
> Addresses-Coverity: ("Explicit null dereferenced")
> Fixes: 72a64c2fe9d8 ("mlxsw: thermal: Read module temperature thresholds using MTMP register")
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Thanks
next prev parent reply other threads:[~2021-06-09 18:07 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-09 17:56 [PATCH][next] mlxsw: thermal: Fix null dereference of NULL temperature parameter Colin King
2021-06-09 18:07 ` Ido Schimmel [this message]
2021-06-09 22:40 ` patchwork-bot+netdevbpf
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=YMEDZ4/7atRSTcOL@shredder \
--to=idosch@idosch.org \
--cc=c_mykolak@nvidia.com \
--cc=colin.king@canonical.com \
--cc=davem@davemloft.net \
--cc=idosch@nvidia.com \
--cc=jiri@nvidia.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=vadimp@nvidia.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox