netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Leon Romanovsky <leon@kernel.org>
To: Peter Kosyh <pkosyh@yandex.ru>
Cc: Tariq Toukan <tariqt@nvidia.com>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	netdev@vger.kernel.org, lvc-project@linuxtesting.org
Subject: Re: [PATCH net v2] net/mlx4: Check retval of mlx4_bitmap_init
Date: Thu, 17 Nov 2022 12:39:19 +0200	[thread overview]
Message-ID: <Y3YPV4csGxEJ6uSl@unreal> (raw)
In-Reply-To: <20221116100806.226699-1-pkosyh@yandex.ru>

On Wed, Nov 16, 2022 at 01:08:06PM +0300, Peter Kosyh wrote:
> If mlx4_bitmap_init fails, mlx4_bitmap_alloc_range will dereference
> the NULL pointer (bitmap->table).
> 
> Make sure, that mlx4_bitmap_alloc_range called in no error case.
> 
> Found by Linux Verification Center (linuxtesting.org) with SVACE.
> 
> Fixes: d57febe1a478 ("net/mlx4: Add A0 hybrid steering")
> 
> Signed-off-by: Peter Kosyh <pkosyh@yandex.ru>
> 
> Reviewed-by: Tariq Toukan <tariqt@nvidia.com>

Please don't add blank lines between tags and your Signed-off-by should
be last.

Thanks

  reply	other threads:[~2022-11-17 10:39 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-16 10:08 [PATCH net v2] net/mlx4: Check retval of mlx4_bitmap_init Peter Kosyh
2022-11-17 10:39 ` Leon Romanovsky [this message]
2022-11-17 15:28   ` [PATCH net v3] " Peter Kosyh
2022-11-19  3:50     ` 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=Y3YPV4csGxEJ6uSl@unreal \
    --to=leon@kernel.org \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kuba@kernel.org \
    --cc=lvc-project@linuxtesting.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=pkosyh@yandex.ru \
    --cc=tariqt@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;
as well as URLs for NNTP newsgroup(s).