netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Leon Romanovsky <leon@kernel.org>
To: Jia-Ju Bai <baijiaju1990@gmail.com>
Cc: borisp@nvidia.com, saeedm@nvidia.com, davem@davemloft.net,
	kuba@kernel.org, netdev@vger.kernel.org,
	linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] net: mellanox: mlx5: fix error return code in mlx5_fpga_device_start()
Date: Sun, 7 Mar 2021 10:50:03 +0200	[thread overview]
Message-ID: <YESTu9lXAgvYaroG@unreal> (raw)
In-Reply-To: <20210304141814.8508-1-baijiaju1990@gmail.com>

On Thu, Mar 04, 2021 at 06:18:14AM -0800, Jia-Ju Bai wrote:
> When mlx5_is_fpga_lookaside() returns a non-zero value, no error
> return code is assigned.
> To fix this bug, err is assigned with -EINVAL as error return code.
>
> Reported-by: TOTE Robot <oslab@tsinghua.edu.cn>
> Signed-off-by: Jia-Ju Bai <baijiaju1990@gmail.com>
> ---
>  drivers/net/ethernet/mellanox/mlx5/core/fpga/core.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)

Like Heiner said, the current code has correct behavior.
The mlx5_fpga_device_load_check() has same mlx5_is_fpga_lookaside()
check and it is not an error if it returns true.

NAK: Leon Romanovsky <leonro@nvidia.com>

Thanks

  parent reply	other threads:[~2021-03-07  8:50 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-04 14:18 [PATCH] net: mellanox: mlx5: fix error return code in mlx5_fpga_device_start() Jia-Ju Bai
2021-03-04 19:58 ` Heiner Kallweit
2021-03-07  8:50 ` Leon Romanovsky [this message]
2021-03-11 22:51   ` Saeed Mahameed

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=YESTu9lXAgvYaroG@unreal \
    --to=leon@kernel.org \
    --cc=baijiaju1990@gmail.com \
    --cc=borisp@nvidia.com \
    --cc=davem@davemloft.net \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=saeedm@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).