Linux RDMA and InfiniBand development
 help / color / mirror / Atom feed
From: Tariq Toukan <ttoukan.linux@gmail.com>
To: Dan Carpenter <dan.carpenter@linaro.org>,
	Tariq Toukan <tariqt@nvidia.com>
Cc: "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, linux-rdma@vger.kernel.org,
	kernel-janitors@vger.kernel.org
Subject: Re: [PATCH net-next] net/mlx4: clean up a type issue
Date: Tue, 25 Jul 2023 21:55:14 +0300	[thread overview]
Message-ID: <f0190c1c-3b2c-ed8d-b0e6-8176f756630a@gmail.com> (raw)
In-Reply-To: <52d0814a-7287-4160-94b5-ac7939ac61c6@moroto.mountain>



On 25/07/2023 8:39, Dan Carpenter wrote:
> These functions returns type bool, not pointers, so return false instead
> of NULL.
> 
> Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
> ---
> Not a bug.  Targetting net-next.
> 
>   drivers/net/ethernet/mellanox/mlx4/mcg.c | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/ethernet/mellanox/mlx4/mcg.c b/drivers/net/ethernet/mellanox/mlx4/mcg.c
> index f1716a83a4d3..24d0c7c46878 100644
> --- a/drivers/net/ethernet/mellanox/mlx4/mcg.c
> +++ b/drivers/net/ethernet/mellanox/mlx4/mcg.c
> @@ -294,7 +294,7 @@ static bool check_duplicate_entry(struct mlx4_dev *dev, u8 port,
>   	struct mlx4_promisc_qp *dqp, *tmp_dqp;
>   
>   	if (port < 1 || port > dev->caps.num_ports)
> -		return NULL;
> +		return false;
>   
>   	s_steer = &mlx4_priv(dev)->steer[port - 1];
>   
> @@ -375,7 +375,7 @@ static bool can_remove_steering_entry(struct mlx4_dev *dev, u8 port,
>   	bool ret = false;
>   
>   	if (port < 1 || port > dev->caps.num_ports)
> -		return NULL;
> +		return false;
>   
>   	s_steer = &mlx4_priv(dev)->steer[port - 1];
>   

Thanks for your patch.
Reviewed-by: Tariq Toukan <tariqt@nvidia.com>

  parent reply	other threads:[~2023-07-25 18:55 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-25  5:39 [PATCH net-next] net/mlx4: clean up a type issue Dan Carpenter
2023-07-25  5:42 ` Randy Dunlap
2023-07-25  5:47 ` Leon Romanovsky
2023-07-25 18:55 ` Tariq Toukan [this message]
2023-07-27  5:20 ` 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=f0190c1c-3b2c-ed8d-b0e6-8176f756630a@gmail.com \
    --to=ttoukan.linux@gmail.com \
    --cc=dan.carpenter@linaro.org \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --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