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: <10f0634f-06de-4a35-8341-5e35d4ce6205@linux.dev>
Date: Thu, 18 Sep 2025 13:57:44 +0100
From: Vadim Fedorenko <vadim.fedorenko@...ux.dev>
To: Dan Carpenter <dan.carpenter@...aro.org>, Fan Gong <gongfan1@...wei.com>
Cc: Andrew Lunn <andrew+netdev@...n.ch>, "David S. Miller"
 <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>,
 Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
 Zhu Yikai <zhuyikai1@...artners.com>, netdev@...r.kernel.org,
 linux-kernel@...r.kernel.org, kernel-janitors@...r.kernel.org
Subject: Re: [PATCH net-next] hinic3: Fix NULL vs IS_ERR() check in
 hinic3_alloc_rxqs_res()

On 18/09/2025 10:45, Dan Carpenter wrote:
> The page_pool_create() function never returns NULL, it returns
> error pointers.  Update the check to match.
> 
> Fixes: 73f37a7e1993 ("hinic3: Queue pair resource initialization")
> Signed-off-by: Dan Carpenter <dan.carpenter@...aro.org>
> ---
>   drivers/net/ethernet/huawei/hinic3/hinic3_rx.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ethernet/huawei/hinic3/hinic3_rx.c b/drivers/net/ethernet/huawei/hinic3/hinic3_rx.c
> index 6cfe3bdd8ee5..16c00c3bb1ed 100644
> --- a/drivers/net/ethernet/huawei/hinic3/hinic3_rx.c
> +++ b/drivers/net/ethernet/huawei/hinic3/hinic3_rx.c
> @@ -414,7 +414,7 @@ int hinic3_alloc_rxqs_res(struct net_device *netdev, u16 num_rq,
>   		pp_params.dma_dir = DMA_FROM_DEVICE;
>   		pp_params.max_len = PAGE_SIZE;
>   		rqres->page_pool = page_pool_create(&pp_params);
> -		if (!rqres->page_pool) {
> +		if (IS_ERR(rqres->page_pool)) {
>   			netdev_err(netdev, "Failed to create rxq%d page pool\n",
>   				   idx);
>   			goto err_free_cqe;

Reviewed-by: Vadim Fedorenko <vadim.fedorenko@...ux.dev>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ