lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <f0190c1c-3b2c-ed8d-b0e6-8176f756630a@gmail.com>
Date: Tue, 25 Jul 2023 21:55:14 +0300
From: Tariq Toukan <ttoukan.linux@...il.com>
To: Dan Carpenter <dan.carpenter@...aro.org>, Tariq Toukan <tariqt@...dia.com>
Cc: "David S. Miller" <davem@...emloft.net>,
 Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>,
 Paolo Abeni <pabeni@...hat.com>, netdev@...r.kernel.org,
 linux-rdma@...r.kernel.org, kernel-janitors@...r.kernel.org
Subject: Re: [PATCH net-next] net/mlx4: clean up a type issue



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@...aro.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@...dia.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ