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: <4f60e3d9-976d-3e3a-b695-9ecc73818cd1@hisilicon.com>
Date:   Mon, 6 Mar 2023 11:06:56 +0800
From:   "chenxiang (M)" <chenxiang66@...ilicon.com>
To:     void0red <void0red@...il.com>
CC:     <jejb@...ux.ibm.com>, <martin.petersen@...cle.com>,
        <linux-scsi@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] scsi: hisi_sas: add a check of devm_add_action

Hi,


在 2023/2/27 11:10, void0red 写道:
> From: Kang Chen <void0red@...il.com>
>
> devm_add_action may fails, check it in the caller of
> interrupt_preinit_v3_hw
>
> Signed-off-by: Kang Chen <void0red@...il.com>

Acked-by: Xiang Chen <chenxiang66@...ilicon.com>
Thanks!

> ---
>   drivers/scsi/hisi_sas/hisi_sas_v3_hw.c | 3 +--
>   1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/scsi/hisi_sas/hisi_sas_v3_hw.c b/drivers/scsi/hisi_sas/hisi_sas_v3_hw.c
> index 0c3fcb807..a63279f55 100644
> --- a/drivers/scsi/hisi_sas/hisi_sas_v3_hw.c
> +++ b/drivers/scsi/hisi_sas/hisi_sas_v3_hw.c
> @@ -2495,8 +2495,7 @@ static int interrupt_preinit_v3_hw(struct hisi_hba *hisi_hba)
>   	hisi_hba->cq_nvecs = vectors - BASE_VECTORS_V3_HW;
>   	shost->nr_hw_queues = hisi_hba->cq_nvecs;
>   
> -	devm_add_action(&pdev->dev, hisi_sas_v3_free_vectors, pdev);
> -	return 0;
> +	return devm_add_action(&pdev->dev, hisi_sas_v3_free_vectors, pdev);
>   }
>   
>   static int interrupt_init_v3_hw(struct hisi_hba *hisi_hba)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ